gh-142961: Fix constant folding len(tuple) in JIT (GH-142963)

This commit is contained in:
Ken Jin 2025-12-20 01:43:36 +08:00 committed by GitHub
parent 049c2526bf
commit 786f464c74
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
8 changed files with 931 additions and 777 deletions

View file

@ -5285,6 +5285,13 @@ dummy_func(
value = PyStackRef_FromPyObjectBorrow(ptr);
}
tier2 op(_SHUFFLE_3_LOAD_CONST_INLINE_BORROW, (ptr/4, callable, null, arg -- res, a, c)) {
res = PyStackRef_FromPyObjectBorrow(ptr);
a = arg;
c = callable;
INPUTS_DEAD();
}
tier2 op(_POP_CALL_TWO_LOAD_CONST_INLINE_BORROW, (ptr/4, callable, null, pop1, pop2 -- value)) {
PyStackRef_CLOSE(pop2);
PyStackRef_CLOSE(pop1);