Skip to content

Commit 89cc6ef

Browse files
committed
Break apart the main native-to-llvm converter and the per-function converter.
1 parent 1ee4de3 commit 89cc6ef

File tree

5 files changed

+1600
-1555
lines changed

5 files changed

+1600
-1555
lines changed

typed_python/compiler/native_compiler/llvm_execution_engine.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,9 @@
1414

1515
import llvmlite.binding as llvm
1616
import llvmlite.ir
17-
import typed_python.compiler.native_compiler.native_ast_to_llvm as native_ast_to_llvm
17+
import typed_python.compiler.native_compiler.native_ast_to_llvm_function_converter as \
18+
native_ast_to_llvm_function_converter
19+
1820

1921
import ctypes
2022
from typed_python import _types
@@ -36,15 +38,15 @@
3638
.get_abi_size(target_machine.target_data)
3739
)
3840

39-
assert pointer_size == native_ast_to_llvm.pointer_size
41+
assert pointer_size == native_ast_to_llvm_function_converter.pointer_size
4042

4143

4244
def sizeof_native_type(native_type):
4345
if native_type.matches.Void:
4446
return 0
4547

4648
return (
47-
native_ast_to_llvm.type_to_llvm_type(native_type)
49+
native_ast_to_llvm_function_converter.type_to_llvm_type(native_type)
4850
.get_abi_size(target_machine.target_data)
4951
)
5052

0 commit comments

Comments
 (0)