rust-lang / rustc_codegen_gcc

libgccjit AOT codegen for rustc
Apache License 2.0
920 stars 60 forks source link

Error in the libgccjit 12 CI #270

Closed antoyo closed 1 year ago

antoyo commented 1 year ago

https://github.com/rust-lang/rustc_codegen_gcc/actions/runs/4715557516/jobs/8362625048#step:19:78

libgccjit.so: error: gcc_jit_context_new_array_type: negative size
gcc_jit_type_get_pointer: NULL type
libgccjit.so: error: gcc_jit_context_new_bitcast: NULL type
gcc_jit_rvalue_get_type: NULL rvalue
gcc_jit_type_is_pointer: NULL type
gcc_jit_type_get_pointer: NULL type
gcc_jit_rvalue_get_type: NULL rvalue
gcc_jit_compatible_types: NULL rtype
gcc_jit_compatible_types: NULL rtype
gcc_jit_compatible_types: NULL rtype
gcc_jit_compatible_types: NULL rtype
gcc_jit_compatible_types: NULL rtype
gcc_jit_compatible_types: NULL rtype
gcc_jit_compatible_types: NULL rtype
gcc_jit_compatible_types: NULL rtype
gcc_jit_compatible_types: NULL rtype
gcc_jit_compatible_types: NULL rtype
gcc_jit_compatible_types: NULL ltype
libgccjit.so: error: gcc_jit_context_new_array_access: NULL ptr
gcc_jit_lvalue_as_rvalue: NULL lvalue
libgccjit.so: error: gcc_jit_context_new_cast: NULL rvalue
gcc_jit_rvalue_get_type: NULL rvalue
gcc_jit_rvalue_get_type: NULL rvalue
libgccjit.so: error: gcc_jit_context_new_cast: NULL rvalue
gcc_jit_rvalue_get_type: NULL rvalue
gcc_jit_rvalue_get_type: NULL rvalue
gcc_jit_type_dyncast_vector: NULL type
gcc_jit_type_unqualified: NULL type
gcc_jit_type_is_integral: NULL type
gcc_jit_type_is_pointer: NULL type
gcc_jit_type_dyncast_vector: NULL type
gcc_jit_type_unqualified: NULL type
gcc_jit_type_dyncast_vector: NULL type
gcc_jit_type_unqualified: NULL type
gcc_jit_rvalue_get_type: NULL rvalue
gcc_jit_rvalue_get_type: NULL rvalue
libgccjit.so: error: gcc_jit_context_new_bitcast: NULL rvalue
libgccjit.so: error: gcc_jit_context_new_call_through_ptr: NULL argument 1 to fn_ptr: _RNvMNtCs7A132rBG1o3_4core5sliceSu4iterCs4w92M9ewiLd_9coretests (type: struct struct[0] *)
gcc_jit_rvalue_get_type: NULL rvalue
libgccjit.so: error: gcc_jit_function_new_local: NULL type
libgccjit.so: error: gcc_jit_block_add_assignment: NULL lvalue
gcc_jit_lvalue_as_rvalue: NULL lvalue
gcc_jit_rvalue_get_type: NULL rvalue
gcc_jit_type_dyncast_array: NULL type
gcc_jit_type_dyncast_vector: NULL type
gcc_jit_type_is_pointer: NULL type
gcc_jit_type_is_struct: NULL type
gcc_jit_type_as_object: NULL type
gcc_jit_object_get_debug_string: NULL object

This error is likely caused because I removed the code to adjust the size of arrays and libgccjit 12 still requires an int instead of a 64-bit integer.

antoyo commented 1 year ago

It seems the sysroot now requires more stuff that is not implemented for the libgccjit12 feature, so I might as well remove this feature and do this instead.

I can disable the libgccjit12 CI in the meantime.

antoyo commented 1 year ago

Perhaps I removed some patch to the sysroot disabling SIMD.

antoyo commented 1 year ago

Fixed by #357.