fix: Add missing set_fast_math method#149
Conversation
OSL ChatGPT ReviewerNOTE: This is generated by an AI program, so some comments may not make sense. src/irx/builders/llvmliteir.py
|
|
@yuvimittal please review! |
|
@yuvimittal & @xmnlab please review the pr! |
|
@iihimanshuu , i dont understand in which file does we call |
|
Thanks for looking at this. I opened this PR because set_fast_math() was being called but wasn’t defined at the time (Dec 15). I see you’ve since implemented a proper solution with tests on main, so my change is now redundant. I’ll close this PR—appreciate the quick fix!
|
Description:
Problem:
llvmliteir.py calls
self.set_fast_math()at lines 603, 608, 612, and 660, but the method doesn't exist, causingAttributeErrorat runtime for vector operations with fast math.Solution:
Added
set_fast_math(enable: bool)method that enables/disables fast math flags on the LLVM IR builder using llvmlite'sset_fastmath_flags(["fast"])andclear_fastmath_flags()methods.Closes #148
Reviewer's checklist
Copy and paste this template for your review's note: