Closed smarr closed 3 years ago
To reproduce, grab https://github.com/smarr/are-we-fast-yet/tree/932b44ec0a5f004454720a2069413cb9ada76bcb/benchmarks/Python
and run graalpython harness.py harness.py Havlak 100 1500
graalpython harness.py harness.py Havlak 100 1500
The clear operations here seem to cause (eventually, probably not directly) code invalidation, which means it keeps recompiling:
https://github.com/smarr/are-we-fast-yet/blob/932b44ec0a5f004454720a2069413cb9ada76bcb/benchmarks/Python/havlak.py#L368-L369
Replacing them with a simple new list leads to code that's 10x as fast.
Thank you for the report. I'll take a look shortly.
To reproduce, grab https://github.com/smarr/are-we-fast-yet/tree/932b44ec0a5f004454720a2069413cb9ada76bcb/benchmarks/Python
and run
graalpython harness.py harness.py Havlak 100 1500
The clear operations here seem to cause (eventually, probably not directly) code invalidation, which means it keeps recompiling:
https://github.com/smarr/are-we-fast-yet/blob/932b44ec0a5f004454720a2069413cb9ada76bcb/benchmarks/Python/havlak.py#L368-L369
Replacing them with a simple new list leads to code that's 10x as fast.