File tree 3 files changed +9
-0
lines changed
3 files changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -8552,6 +8552,8 @@ static jl_llvm_functions_t
8552
8552
Type *RT = Arg->getParamStructRetType ();
8553
8553
TypeSize sz = DL.getTypeAllocSize (RT);
8554
8554
Align al = DL.getPrefTypeAlign (RT);
8555
+ if (al > MAX_ALIGN)
8556
+ al = Align (MAX_ALIGN);
8555
8557
param.addAttribute (Attribute::NonNull);
8556
8558
// The `dereferenceable` below does not imply `nonnull` for non addrspace(0) pointers.
8557
8559
param.addDereferenceableAttr (sz);
Original file line number Diff line number Diff line change @@ -754,6 +754,8 @@ void jl_compute_field_offsets(jl_datatype_t *st)
754
754
if (al > alignm )
755
755
alignm = al ;
756
756
}
757
+ if (alignm > MAX_ALIGN )
758
+ alignm = MAX_ALIGN ; // We cannot guarantee alignments over 16 bytes because that's what our heap is aligned as
757
759
if (LLT_ALIGN (sz , alignm ) > sz ) {
758
760
haspadding = 1 ;
759
761
sz = LLT_ALIGN (sz , alignm );
Original file line number Diff line number Diff line change 933
933
end
934
934
nothing
935
935
end
936
+
937
+ struct Vec56937 x:: NTuple{8, VecElement{Int}} end
938
+
939
+ x56937 = Ref (Vec56937 (ntuple (_-> VecElement (1 ),8 )))
940
+ @test x56937[]. x[1 ] == VecElement {Int} (1 ) # shouldn't crash
You can’t perform that action at this time.
0 commit comments