Skip to content

Init runtime PAL in RunnerTest (forward fix for D108707577)#20319

Merged
Gasoonjia merged 1 commit into
mainfrom
export-D108831322
Jun 17, 2026
Merged

Init runtime PAL in RunnerTest (forward fix for D108707577)#20319
Gasoonjia merged 1 commit into
mainfrom
export-D108831322

Conversation

@Gasoonjia

Copy link
Copy Markdown
Contributor

Summary:
Forward fix for D108707577 (llm_runner: plumb prefill temperature, #20244).

The new test RunnerTest.TextTokenGeneratorRejectsTemperatureOutOfRange aborts:

[ RUN ] RunnerTest.TextTokenGeneratorRejectsTemperatureOutOfRange
ExecuTorch PAL must be initialized before call to et_pal_current_ticks()
*** Signal 6 (SIGABRT) ***

The new test drives the temperature-rejection path, which emits an ET_LOG (and
thus calls et_pal_current_ticks()) before any model load. The RunnerTest fixture
never initializes the ExecuTorch runtime, so the timer call aborts. The valid-
temperature tests in the same fixture pass because their happy path does not log.

Fix: initialize the runtime in RunnerTest::SetUp(), matching the established
pattern used by the sibling tests in this same directory (test_text_prefiller,
test_util, test_wav_loader all call executorch::runtime::runtime_init() in
SetUp()). Applied to both the fbcode and xplat copies.

Differential Revision: D108831322

Summary:
Forward fix for D108707577 (llm_runner: plumb prefill temperature, #20244).

The new test RunnerTest.TextTokenGeneratorRejectsTemperatureOutOfRange aborts:

  [ RUN ] RunnerTest.TextTokenGeneratorRejectsTemperatureOutOfRange
  ExecuTorch PAL must be initialized before call to et_pal_current_ticks()
  *** Signal 6 (SIGABRT) ***

The new test drives the temperature-rejection path, which emits an ET_LOG (and
thus calls et_pal_current_ticks()) before any model load. The RunnerTest fixture
never initializes the ExecuTorch runtime, so the timer call aborts. The valid-
temperature tests in the same fixture pass because their happy path does not log.

Fix: initialize the runtime in RunnerTest::SetUp(), matching the established
pattern used by the sibling tests in this same directory (test_text_prefiller,
test_util, test_wav_loader all call executorch::runtime::runtime_init() in
SetUp()). Applied to both the fbcode and xplat copies.

Differential Revision: D108831322
@pytorch-bot

pytorch-bot Bot commented Jun 17, 2026

Copy link
Copy Markdown

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/20319

Note: Links to docs will display an error until the docs builds have been completed.

❌ 1 New Failure, 1 Cancelled Job, 2 Unrelated Failures

As of commit 3cc44f5 with merge base 218cc45 (image):

NEW FAILURE - The following job has failed:

CANCELLED JOB - The following job was cancelled. Please retry:

BROKEN TRUNK - The following jobs failed but were present on the merge base:

👉 Rebase onto the `viable/strict` branch to avoid these failures

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Jun 17, 2026
@meta-codesync

meta-codesync Bot commented Jun 17, 2026

Copy link
Copy Markdown
Contributor

@Gasoonjia has exported this pull request. If you are a Meta employee, you can view the originating Diff in D108831322.

@github-actions

Copy link
Copy Markdown

This PR needs a release notes: label

If your change should be included in the release notes (i.e. would users of this library care about this change?), please use a label starting with release notes:. This helps us keep track and include your important work in the next release notes.

To add a label, you can comment to pytorchbot, for example
@pytorchbot label "release notes: none"

For more information, see
https://github.com/pytorch/pytorch/wiki/PyTorch-AutoLabel-Bot#why-categorize-for-release-notes-and-how-does-it-work.

@Gasoonjia Gasoonjia merged commit e2bc39b into main Jun 17, 2026
185 of 193 checks passed
@Gasoonjia Gasoonjia deleted the export-D108831322 branch June 17, 2026 06:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. meta-exported

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants