diff --git a/src/compiler/ast.c b/src/compiler/ast.c index 3a08bf9ea..8ee09d1b9 100644 --- a/src/compiler/ast.c +++ b/src/compiler/ast.c @@ -251,7 +251,7 @@ void decl_set_external_name(Decl *decl) } } // Concat with the name - scratch_buffer_append("_"); + scratch_buffer_append(decl->is_export ? "_" : "."); scratch_buffer_append(name); // Copy it to extname diff --git a/src/compiler/compiler_internal.h b/src/compiler/compiler_internal.h index 2d77aa229..b8cd331b7 100644 --- a/src/compiler/compiler_internal.h +++ b/src/compiler/compiler_internal.h @@ -1584,6 +1584,7 @@ struct CompilationUnit_ Decl **faulttypes; Visibility default_visibility; bool export_by_default; + bool test_by_default; struct { // Not properly implemented diff --git a/src/compiler/parse_global.c b/src/compiler/parse_global.c index e08604c78..f3a02dbd9 100644 --- a/src/compiler/parse_global.c +++ b/src/compiler/parse_global.c @@ -390,6 +390,9 @@ bool parse_module(ParseContext *c, AstId docs) } switch (attr->attr_kind) { + case ATTRIBUTE_TEST: + c->unit->test_by_default = true; + continue; case ATTRIBUTE_EXPORT: if (attr->exprs) { @@ -427,7 +430,7 @@ bool parse_module(ParseContext *c, AstId docs) default: break; } - SEMA_ERROR(attr, "'%s' cannot be used with the module declaration.", attr->name); + SEMA_ERROR(attr, "'%s' cannot be used after a module declaration.", attr->name); return false; FOREACH_END(); c->unit->default_visibility = visibility; @@ -1080,9 +1083,10 @@ bool parse_attribute(ParseContext *c, Attr **attribute_ref) static bool parse_attributes_for_global(ParseContext *c, Decl *decl) { Visibility visibility = c->unit->default_visibility; + if (decl->decl_kind == DECL_FUNC) decl->func_decl.attr_test = c->unit->test_by_default; + decl->is_export = c->unit->export_by_default; if (!parse_attributes(c, &decl->attributes, &visibility)) return false; decl->visibility = visibility; - decl->is_export = c->unit->export_by_default; return true; } diff --git a/src/compiler/sema_expr.c b/src/compiler/sema_expr.c index 541bc4107..4fea54230 100644 --- a/src/compiler/sema_expr.c +++ b/src/compiler/sema_expr.c @@ -6693,17 +6693,17 @@ static inline bool sema_expr_analyse_lambda(SemaContext *context, Type *func_typ { case CALL_ENV_CHECKS: scratch_buffer_append(unit->module->name->module); - scratch_buffer_append("_checks"); + scratch_buffer_append(".$checks"); break; case CALL_ENV_GLOBAL_INIT: scratch_buffer_append(unit->module->name->module); - scratch_buffer_append("_global"); + scratch_buffer_append(".$global"); break; case CALL_ENV_FUNCTION: if (context->current_macro) { scratch_buffer_append(unit->module->name->module); - scratch_buffer_append("_"); + scratch_buffer_append("."); scratch_buffer_append(context->current_macro->name); } else @@ -6713,15 +6713,15 @@ static inline bool sema_expr_analyse_lambda(SemaContext *context, Type *func_typ break; case CALL_ENV_INITIALIZER: scratch_buffer_append(unit->module->name->module); - scratch_buffer_append("_initializer"); + scratch_buffer_append(".$initializer"); break; case CALL_ENV_FINALIZER: scratch_buffer_append(unit->module->name->module); - scratch_buffer_append("_finalizer"); + scratch_buffer_append(".$finalizer"); break; case CALL_ENV_ATTR: scratch_buffer_append(unit->module->name->module); - scratch_buffer_append("_attr"); + scratch_buffer_append(".$attr"); break; } scratch_buffer_append("$lambda"); diff --git a/test/test_suite/abi/aarch64_args.c3t b/test/test_suite/abi/aarch64_args.c3t index 498a388c2..2de1b44db 100644 --- a/test/test_suite/abi/aarch64_args.c3t +++ b/test/test_suite/abi/aarch64_args.c3t @@ -15,7 +15,7 @@ fn void example() { /* #expect: test.ll -define void @test_example() #0 { +define void @test.example() #0 { entry: %l = alloca %Large, align 8 %indirectarg = alloca %Large, align 8 diff --git a/test/test_suite/abi/aarch64_hfa_args.c3t b/test/test_suite/abi/aarch64_hfa_args.c3t index c79fe0917..a1a0d4700 100644 --- a/test/test_suite/abi/aarch64_hfa_args.c3t +++ b/test/test_suite/abi/aarch64_hfa_args.c3t @@ -28,5 +28,5 @@ fn MixedHFAv3 test_mixed(MixedHFAv3 a0, MixedHFAv3 a1, MixedHFAv3 a2) { %HFAv3 = type { [4 x <3 x float>] } %MixedHFAv3 = type { [3 x <3 x float>], <16 x i8> } -define %HFAv3 @test_test([4 x <4 x float>] %0, [4 x <4 x float>] %1, [4 x <4 x float>] %2) -define %MixedHFAv3 @test_test_mixed([4 x <4 x float>] %0, [4 x <4 x float>] %1, [4 x <4 x float>] %2) #0 { +define %HFAv3 @test.test([4 x <4 x float>] %0, [4 x <4 x float>] %1, [4 x <4 x float>] %2) +define %MixedHFAv3 @test.test_mixed([4 x <4 x float>] %0, [4 x <4 x float>] %1, [4 x <4 x float>] %2) #0 { diff --git a/test/test_suite/abi/darwin64_avx.c3t b/test/test_suite/abi/darwin64_avx.c3t index 39bd70659..69405366f 100644 --- a/test/test_suite/abi/darwin64_avx.c3t +++ b/test/test_suite/abi/darwin64_avx.c3t @@ -112,18 +112,18 @@ declare void @f38(<8 x float>) declare void @f37(<8 x float>) declare void @func40(ptr byval(%Two128) align 16) -define void @test_func41(ptr byval(%Two128) align 16 %0) +define void @test.func41(ptr byval(%Two128) align 16 %0) declare void @func42(ptr byval(%Sa) align 16) -define void @test_func43(ptr byval(%Sa) align 16 %0) +define void @test.func43(ptr byval(%Sa) align 16 %0) declare void @f46(double, double, double, double, double, double, double, double, ptr byval(<2 x float>) align 8, ptr byval(<2 x float>) align 8) #0 declare void @f47(i32, i32, i32, i32, i32, i32, i32) -declare void @test_test49_helper(double, ...) -define void @test_test49(double %0, double %1) +declare void @test.test49_helper(double, ...) +define void @test.test49(double %0, double %1) entry: - call void (double, ...) @test_test49_helper(double %0, double %1) + call void (double, ...) @test.test49_helper(double %0, double %1) ret void call void (i32, ...) @test52_helper(i32 0, <8 x float> %0, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double %lo, double %hi) @@ -134,8 +134,8 @@ declare void @f55(ptr byval(%St512) align 64) declare void @f56(ptr byval(<16 x float>) align 64) declare void @f58(ptr byval(%Two256) align 32) -define void @test_f59(ptr byval(%Two256) align 32 %0) +define void @test.f59(ptr byval(%Two256) align 32 %0) declare void @f60(ptr byval(%SAtwo256) align 32) -define void @test_f61(ptr byval(%SAtwo256) align 32 %0) #0 { +define void @test.f61(ptr byval(%SAtwo256) align 32 %0) #0 { diff --git a/test/test_suite/abi/darwin64_avx512.c3t b/test/test_suite/abi/darwin64_avx512.c3t index 878abeb00..1f3ed9881 100644 --- a/test/test_suite/abi/darwin64_avx512.c3t +++ b/test/test_suite/abi/darwin64_avx512.c3t @@ -62,13 +62,13 @@ declare void @f55(<16 x float>) #0 declare void @f56(<16 x float>) #0 declare void @f58(ptr byval(%Two256) align 32) #0 -define void @test_f59(ptr byval(%Two256) align 32 %0) #0 { +define void @test.f59(ptr byval(%Two256) align 32 %0) #0 { declare void @f60(ptr byval(%SAtwo256) align 32) #0 -define void @test_f61(ptr byval(%SAtwo256) align 32 %0) #0 { +define void @test.f61(ptr byval(%SAtwo256) align 32 %0) #0 { -define void @test_f62() #0 { - call void (i32, ...) @test_f62_helper(i32 0, <16 x float> %0, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double %lo, double %hi) -define void @test_f64() #0 { - call void (<16 x float>, ...) @test_f64_helper(<16 x float> %0, <16 x float> %1, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double %lo, double %hi) - call void (<16 x float>, ...) @test_f64_helper(<16 x float> %6, <16 x float> %7, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, ptr byval(%Complex) align 8 %literal1) +define void @test.f62() #0 { + call void (i32, ...) @test.f62_helper(i32 0, <16 x float> %0, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double %lo, double %hi) +define void @test.f64() #0 { + call void (<16 x float>, ...) @test.f64_helper(<16 x float> %0, <16 x float> %1, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double %lo, double %hi) + call void (<16 x float>, ...) @test.f64_helper(<16 x float> %6, <16 x float> %7, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, ptr byval(%Complex) align 8 %literal1) diff --git a/test/test_suite/abi/darwin64_sret.c3t b/test/test_suite/abi/darwin64_sret.c3t index bab17c41d..29bd6d7a6 100644 --- a/test/test_suite/abi/darwin64_sret.c3t +++ b/test/test_suite/abi/darwin64_sret.c3t @@ -12,7 +12,7 @@ fn SimdDouble4x4 ident(SimdDouble4x4 x) { /* #expect: foo.ll -define void @foo_ident(ptr noalias sret(%SimdDouble4x4) align 32 %0, ptr byval(%SimdDouble4x4) align 32 %1) #0 { +define void @foo.ident(ptr noalias sret(%SimdDouble4x4) align 32 %0, ptr byval(%SimdDouble4x4) align 32 %1) #0 { entry: call void @llvm.memcpy.p0.p0.i32(ptr align 32 %0, ptr align 32 %1, i32 128, i1 false) ret void diff --git a/test/test_suite/abi/darwin64_sse.c3t b/test/test_suite/abi/darwin64_sse.c3t index 175f8f6fb..383d633f5 100644 --- a/test/test_suite/abi/darwin64_sse.c3t +++ b/test/test_suite/abi/darwin64_sse.c3t @@ -50,7 +50,7 @@ declare void @f38(ptr byval(%St256) align 32) declare void @f37(ptr byval(<8 x float>) align 32) declare void @func40(ptr byval(%Two128) align 16) -define void @test_func41(ptr byval(%Two128) align 16 %0) +define void @test.func41(ptr byval(%Two128) align 16 %0) declare void @func42(ptr byval(%Sa) align 16) -define void @test_func43(ptr byval(%Sa) align 16 %0) +define void @test.func43(ptr byval(%Sa) align 16 %0) diff --git a/test/test_suite/abi/darwin_arg.c3t b/test/test_suite/abi/darwin_arg.c3t index 39502e1b0..9d52311ff 100644 --- a/test/test_suite/abi/darwin_arg.c3t +++ b/test/test_suite/abi/darwin_arg.c3t @@ -20,6 +20,6 @@ fn void f9122143() declare void @d(i64, double) #0 - %lo = load i64, ptr @test_ss, align 16 - %hi = load double, ptr getelementptr inbounds ({ i64, double }, ptr @test_ss, i32 0, i32 1), align 8 + %lo = load i64, ptr @test.ss, align 16 + %hi = load double, ptr getelementptr inbounds ({ i64, double }, ptr @test.ss, i32 0, i32 1), align 8 call void @d(i64 %lo, double %hi) diff --git a/test/test_suite/abi/darwin_return_boolarray.c3t b/test/test_suite/abi/darwin_return_boolarray.c3t index 0b6664587..3b1f4499b 100644 --- a/test/test_suite/abi/darwin_return_boolarray.c3t +++ b/test/test_suite/abi/darwin_return_boolarray.c3t @@ -5,7 +5,7 @@ fn bool[2] get() { return { false, false }; } /* #expect: test.ll -define i16 @test_get() #0 { +define i16 @test.get() #0 { entry: %literal = alloca [2 x i8], align 1 %0 = getelementptr inbounds [2 x i8], ptr %literal, i64 0, i64 0 diff --git a/test/test_suite/abi/darwinx64_1.c3t b/test/test_suite/abi/darwinx64_1.c3t index f332dffbe..bbdf16a09 100644 --- a/test/test_suite/abi/darwinx64_1.c3t +++ b/test/test_suite/abi/darwinx64_1.c3t @@ -37,12 +37,12 @@ fn void f8_2(Struct8 a0) {} /* #expect: test.ll -define zeroext i8 @test_f0() -define signext i16 @test_f1() -define i32 @test_f2() -define float @test_f3() -define double @test_f4() -define void @test_f6(i8 zeroext %0, i16 signext %1, i32 %2, i64 %3, ptr %4) -define void @test_f7(i32 %0) -define i64 @test_f8_1() -define void @test_f8_2(i64 %0) #0 { +define zeroext i8 @test.f0() +define signext i16 @test.f1() +define i32 @test.f2() +define float @test.f3() +define double @test.f4() +define void @test.f6(i8 zeroext %0, i16 signext %1, i32 %2, i64 %3, ptr %4) +define void @test.f7(i32 %0) +define i64 @test.f8_1() +define void @test.f8_2(i64 %0) #0 { diff --git a/test/test_suite/abi/darwinx64_2.c3t b/test/test_suite/abi/darwinx64_2.c3t index 2020851a9..6aefa91f7 100644 --- a/test/test_suite/abi/darwinx64_2.c3t +++ b/test/test_suite/abi/darwinx64_2.c3t @@ -147,40 +147,40 @@ fn V2i32 f36(V2i32 arg) { return arg; } /* #expect: test.ll -define i32 @test_f12_0() -define void @test_f12_1(i32 %0) -define void @test_f13(ptr noalias sret(%St13_0) align 8 %0, i32 %1, i32 %2, i32 %3, i32 %4, ptr byval(%St13_1) align 8 %5, i32 %6) #0 { -define void @test_f14(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i8 signext %6) #0 { -define void @test_f15(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, ptr %6) +define i32 @test.f12_0() +define void @test.f12_1(i32 %0) +define void @test.f13(ptr noalias sret(%St13_0) align 8 %0, i32 %1, i32 %2, i32 %3, i32 %4, ptr byval(%St13_1) align 8 %5, i32 %6) #0 { +define void @test.f14(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i8 signext %6) #0 { +define void @test.f15(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, ptr %6) -define void @test_f16(float %0, float %1, float %2, float %3, float %4, float %5, float %6, float %7, float %8) +define void @test.f16(float %0, float %1, float %2, float %3, float %4, float %5, float %6, float %7, float %8) -define void @test_fl18(i32 %0, i32 %1) -define void @test_f20(ptr byval(%St20) align 32 %0) -define ptr @test_f21(i64 %0, ptr %1) +define void @test.fl18(i32 %0, i32 %1) +define void @test.f20(ptr byval(%St20) align 32 %0) +define ptr @test.f21(i64 %0, ptr %1) -define void @test_f22(i64 %0, i64 %1, i64 %2, i64 %3) +define void @test.f22(i64 %0, i64 %1, i64 %2, i64 %3) entry: %x = alloca %St22s, align 16 %y = alloca %St22s, align 16 -define void @test_f23(i32 %0, i64 %1, i32 %2) -define { i64, i32 } @test_f24(ptr %0, ptr %1) +define void @test.f23(i32 %0, i64 %1, i32 %2) +define { i64, i32 } @test.f24(ptr %0, ptr %1) -define <4 x float> @test_f25(<4 x float> %0) #0 { +define <4 x float> @test.f25(<4 x float> %0) #0 { entry: %fadd = fadd <4 x float> %0, %0 ret <4 x float> %fadd } -define { ptr, ptr } @test_f26(ptr %0) -define <4 x float> @test_f27(<4 x float> %0) -define <8 x float> @test_f27a(<8 x float> %0) -define <8 x float> @test_f27b(<8 x float> %0) -define void @test_f28(double %0, i32 %1) -define void @test_f29a(double %0, i32 %1) -define void @test_f30(i64 %0, i24 %1) -define float @test_f31(<2 x float> %0, float %1) -define double @test_f34(double %0) -define double @test_f35(double %0) -define double @test_f36(double %0) \ No newline at end of file +define { ptr, ptr } @test.f26(ptr %0) +define <4 x float> @test.f27(<4 x float> %0) +define <8 x float> @test.f27a(<8 x float> %0) +define <8 x float> @test.f27b(<8 x float> %0) +define void @test.f28(double %0, i32 %1) +define void @test.f29a(double %0, i32 %1) +define void @test.f30(i64 %0, i24 %1) +define float @test.f31(<2 x float> %0, float %1) +define double @test.f34(double %0) +define double @test.f35(double %0) +define double @test.f36(double %0) \ No newline at end of file diff --git a/test/test_suite/abi/literal_load.c3t b/test/test_suite/abi/literal_load.c3t index 1d03666ed..ceea530eb 100644 --- a/test/test_suite/abi/literal_load.c3t +++ b/test/test_suite/abi/literal_load.c3t @@ -17,7 +17,7 @@ fn Test creator() /* #expect: literal_load.ll -define i32 @literal_load_creator() #0 { +define i32 @literal_load.creator() #0 { entry: %literal = alloca %Test, align 4 %literal1 = alloca %Test, align 4 diff --git a/test/test_suite/abi/literal_load_aarch64.c3t b/test/test_suite/abi/literal_load_aarch64.c3t index d9c3ef29e..67328d899 100644 --- a/test/test_suite/abi/literal_load_aarch64.c3t +++ b/test/test_suite/abi/literal_load_aarch64.c3t @@ -20,7 +20,7 @@ fn Test creator() declare void @blorg(i64) #0 -define i32 @literal_load_creator() #0 { +define i32 @literal_load.creator() #0 { entry: %literal = alloca %Test, align 4 %literal1 = alloca %Test, align 4 diff --git a/test/test_suite/abi/literal_load_mingw.c3t b/test/test_suite/abi/literal_load_mingw.c3t index 3bf6b59a5..656d6ecd8 100644 --- a/test/test_suite/abi/literal_load_mingw.c3t +++ b/test/test_suite/abi/literal_load_mingw.c3t @@ -18,7 +18,7 @@ fn Test creator() /* #expect: literal_load.ll -define i32 @literal_load_creator() #0 { +define i32 @literal_load.creator() #0 { entry: %literal = alloca %Test, align 4 %literal1 = alloca %Test, align 4 diff --git a/test/test_suite/abi/pass_large_aarch.c3t b/test/test_suite/abi/pass_large_aarch.c3t index ad4f36305..52e15789a 100644 --- a/test/test_suite/abi/pass_large_aarch.c3t +++ b/test/test_suite/abi/pass_large_aarch.c3t @@ -19,7 +19,7 @@ fn void example() /* #expect: pass_large.ll -define void @pass_large_example() +define void @pass_large.example() entry: %l = alloca %Large, align 8 %indirectarg = alloca %Large, align 8 diff --git a/test/test_suite/abi/riscv32-ilp32-abi.c3t b/test/test_suite/abi/riscv32-ilp32-abi.c3t index 84f6606b3..b181ed603 100644 --- a/test/test_suite/abi/riscv32-ilp32-abi.c3t +++ b/test/test_suite/abi/riscv32-ilp32-abi.c3t @@ -48,7 +48,7 @@ fn void f_agg_stack(double a, long b, double c, long d, Tiny e, /* #expect: test.ll -define i32 @test_f_scalar_stack_1(i32 %0, i64 %1, float %2, double %3, fp128 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { +define i32 @test.f_scalar_stack_1(i32 %0, i64 %1, float %2, double %3, fp128 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { entry: %sisiext = sext i8 %6 to i32 %uisiext = zext i8 %7 to i32 @@ -57,7 +57,7 @@ entry: } -define void @test_f_scalar_stack_2(ptr noalias sret(%Large) align 4 %0, float %1, i64 %2, double %3, fp128 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { +define void @test.f_scalar_stack_2(ptr noalias sret(%Large) align 4 %0, float %1, i64 %2, double %3, fp128 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { entry: %literal = alloca %Large, align 4 %8 = getelementptr inbounds %Large, ptr %literal, i32 0, i32 0 @@ -77,13 +77,13 @@ entry: } -define void @test_f_scalar_stack_3(double %0, i64 %1, double %2, i64 %3, i32 %4, i64 %5, float %6, double %7, fp128 %8) #0 { +define void @test.f_scalar_stack_3(double %0, i64 %1, double %2, i64 %3, i32 %4, i64 %5, float %6, double %7, fp128 %8) #0 { entry: ret void } -define void @test_f_agg_stack(double %0, i64 %1, double %2, i64 %3, i32 %4, [2 x i32] %5, i64 %6, ptr align 4 %7) #0 { +define void @test.f_agg_stack(double %0, i64 %1, double %2, i64 %3, i32 %4, [2 x i32] %5, i64 %6, ptr align 4 %7) #0 { entry: %e = alloca %Tiny, align 1 %f = alloca %Small, align 4 diff --git a/test/test_suite/abi/riscv32-ilp32-ilp32f-abi-1.c3t b/test/test_suite/abi/riscv32-ilp32-ilp32f-abi-1.c3t index 99ef18073..38dc2df10 100644 --- a/test/test_suite/abi/riscv32-ilp32-ilp32f-abi-1.c3t +++ b/test/test_suite/abi/riscv32-ilp32-ilp32f-abi-1.c3t @@ -45,7 +45,7 @@ fn void f_agg_stack(double a, long b, double c, long d, Tiny e, /* #expect: test.ll -define i32 @test_f_scalar_stack_1(i32 %0, i64 %1, i32 %2, double %3, fp128 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { +define i32 @test.f_scalar_stack_1(i32 %0, i64 %1, i32 %2, double %3, fp128 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { entry: %sisiext = sext i8 %6 to i32 %uisiext = zext i8 %7 to i32 @@ -53,7 +53,7 @@ entry: ret i32 %add } -define void @test_f_scalar_stack_2(ptr noalias sret(%Large) align 4 %0, i32 %1, i64 %2, double %3, fp128 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { +define void @test.f_scalar_stack_2(ptr noalias sret(%Large) align 4 %0, i32 %1, i64 %2, double %3, fp128 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { entry: %literal = alloca %Large, align 4 %8 = getelementptr inbounds %Large, ptr %literal, i32 0, i32 0 @@ -71,12 +71,12 @@ entry: ret void } -define void @test_f_scalar_stack_3(double %0, i64 %1, double %2, i64 %3, i32 %4, i64 %5, i32 %6, double %7, fp128 %8) #0 { +define void @test.f_scalar_stack_3(double %0, i64 %1, double %2, i64 %3, i32 %4, i64 %5, i32 %6, double %7, fp128 %8) #0 { entry: ret void } -define void @test_f_agg_stack(double %0, i64 %1, double %2, i64 %3, i32 %4, [2 x i32] %5, i64 %6, ptr align 4 %7) #0 { +define void @test.f_agg_stack(double %0, i64 %1, double %2, i64 %3, i32 %4, [2 x i32] %5, i64 %6, ptr align 4 %7) #0 { entry: %e = alloca %Tiny, align 1 %f = alloca %Small, align 4 diff --git a/test/test_suite/abi/riscv32-ilp32-ilp32f-abi-2.c3t b/test/test_suite/abi/riscv32-ilp32-ilp32f-abi-2.c3t index 5b36f485e..69cae96e6 100644 --- a/test/test_suite/abi/riscv32-ilp32-ilp32f-abi-2.c3t +++ b/test/test_suite/abi/riscv32-ilp32-ilp32f-abi-2.c3t @@ -46,12 +46,12 @@ fn void f_agg_stack(double a, long b, double c, long d, Tiny e, /* #expect: test.ll -define i32 @test_f_scalar_stack_1(i32 %0, i64 %1, i32 %2, double %3, fp128 %4, i8 zeroext %5, i8 %6, i8 %7) +define i32 @test.f_scalar_stack_1(i32 %0, i64 %1, i32 %2, double %3, fp128 %4, i8 zeroext %5, i8 %6, i8 %7) -define void @test_f_scalar_stack_2(ptr noalias sret(%Large) align 4 %0, i32 %1, i64 %2, double %3, fp128 %4, i8 zeroext %5, i8 %6, i8 %7) +define void @test.f_scalar_stack_2(ptr noalias sret(%Large) align 4 %0, i32 %1, i64 %2, double %3, fp128 %4, i8 zeroext %5, i8 %6, i8 %7) -define void @test_f_scalar_stack_3(double %0, i64 %1, double %2, i64 %3, i32 %4, i64 %5, i32 %6, double %7, fp128 %8) +define void @test.f_scalar_stack_3(double %0, i64 %1, double %2, i64 %3, i32 %4, i64 %5, i32 %6, double %7, fp128 %8) -define void @test_f_agg_stack(double %0, i64 %1, double %2, i64 %3, i32 %4, [2 x i32] %5, i64 %6, ptr align 4 %7) +define void @test.f_agg_stack(double %0, i64 %1, double %2, i64 %3, i32 %4, [2 x i32] %5, i64 %6, ptr align 4 %7) diff --git a/test/test_suite/abi/riscv32-ilp32-ilp32f-ilp32d-abi-1.c3t b/test/test_suite/abi/riscv32-ilp32-ilp32f-ilp32d-abi-1.c3t index ff6ee5383..8e140b66d 100644 --- a/test/test_suite/abi/riscv32-ilp32-ilp32f-ilp32d-abi-1.c3t +++ b/test/test_suite/abi/riscv32-ilp32-ilp32f-ilp32d-abi-1.c3t @@ -89,7 +89,6 @@ fn void f_vec_small_v1i64(long[<1>] x) { x[0] = 114; } -// CHECK-LABEL: define{{.*}} i64 @f_vec_small_v1i64_ret() fn long[<1>] f_vec_small_v1i64_ret() { return {1}; } @@ -115,7 +114,6 @@ struct Large { int a, b, c, d; } -// CHECK-LABEL: define{{.*}} void @f_agg_large(%struct.large* %x) fn void f_agg_large(Large x) { x.a = x.b + x.c + x.d; } @@ -181,67 +179,57 @@ fn void f_va_caller() { /* #expect: test.ll -define void @test_f_void() #0 { +define void @test.f_void() #0 { entry: ret void } - -define zeroext i8 @test_f_scalar_0(i8 zeroext %0) #0 { +define zeroext i8 @test.f_scalar_0(i8 zeroext %0) #0 { entry: ret i8 %0 } - -define signext i8 @test_f_scalar_1(i8 signext %0) #0 { +define signext i8 @test.f_scalar_1(i8 signext %0) #0 { entry: ret i8 %0 } - -define zeroext i8 @test_f_scalar_2(i8 zeroext %0) #0 { +define zeroext i8 @test.f_scalar_2(i8 zeroext %0) #0 { entry: ret i8 %0 } - -define i32 @test_f_scalar_3(i32 %0) #0 { +define i32 @test.f_scalar_3(i32 %0) #0 { entry: ret i32 %0 } - -define i64 @test_f_scalar_4(i64 %0) #0 { +define i64 @test.f_scalar_4(i64 %0) #0 { entry: ret i64 %0 } - -define i128 @test_f_scalar_5(i128 %0) #0 { +define i128 @test.f_scalar_5(i128 %0) #0 { entry: ret i128 %0 } - -define float @test_f_fp_scalar_1(float %0) #0 { +define float @test.f_fp_scalar_1(float %0) #0 { entry: ret float %0 } - -define double @test_f_fp_scalar_2(double %0) #0 { +define double @test.f_fp_scalar_2(double %0) #0 { entry: ret double %0 } - -define fp128 @test_f_fp_scalar_3(fp128 %0) #0 { +define fp128 @test.f_fp_scalar_3(fp128 %0) #0 { entry: ret fp128 %0 } - -define void @test_f_agg_tiny(i32 %0) #0 { +define void @test.f_agg_tiny(i32 %0) #0 { entry: %x = alloca %Tiny, align 1 store i32 %0, ptr %x, align 1 @@ -260,8 +248,7 @@ entry: ret void } - -define i32 @test_f_agg_tiny_ret() #0 { +define i32 @test.f_agg_tiny_ret() #0 { entry: %literal = alloca %Tiny, align 1 %0 = getelementptr inbounds %Tiny, ptr %literal, i32 0, i32 0 @@ -276,8 +263,7 @@ entry: ret i32 %4 } - -define void @test_f_vec_tiny_v4i8(i32 %0) #0 { +define void @test.f_vec_tiny_v4i8(i32 %0) #0 { entry: %x = alloca <4 x i8>, align 4 store i32 %0, ptr %x, align 4 @@ -294,8 +280,7 @@ entry: ret void } - -define i32 @test_f_vec_tiny_v4i8_ret() #0 { +define i32 @test.f_vec_tiny_v4i8_ret() #0 { entry: %taddr = alloca <4 x i8>, align 4 store <4 x i8> , ptr %taddr, align 4 @@ -304,7 +289,7 @@ entry: } -define void @test_f_vec_tiny_v1i32(i32 %0) #0 { +define void @test.f_vec_tiny_v1i32(i32 %0) #0 { entry: %x = alloca <1 x i32>, align 4 store i32 %0, ptr %x, align 4 @@ -314,8 +299,7 @@ entry: ret void } - -define i32 @test_f_vec_tiny_v1i32_ret() #0 { +define i32 @test.f_vec_tiny_v1i32_ret() #0 { entry: %taddr = alloca <1 x i32>, align 4 store <1 x i32> , ptr %taddr, align 4 @@ -323,8 +307,7 @@ entry: ret i32 %0 } - -define void @test_f_agg_small([2 x i32] %0) #0 { +define void @test.f_agg_small([2 x i32] %0) #0 { entry: %x = alloca %Small, align 4 store [2 x i32] %0, ptr %x, align 4 @@ -341,8 +324,7 @@ entry: ret void } - -define [2 x i32] @test_f_agg_small_ret() #0 { +define [2 x i32] @test.f_agg_small_ret() #0 { entry: %literal = alloca %Small, align 4 %0 = getelementptr inbounds %Small, ptr %literal, i32 0, i32 0 @@ -353,8 +335,7 @@ entry: ret [2 x i32] %2 } - -define void @test_f_vec_small_v8i8(i64 %0) #0 { +define void @test.f_vec_small_v8i8(i64 %0) #0 { entry: %x = alloca <8 x i8>, align 8 store i64 %0, ptr %x, align 8 @@ -366,8 +347,7 @@ entry: ret void } - -define i64 @test_f_vec_small_v8i8_ret() #0 { +define i64 @test.f_vec_small_v8i8_ret() #0 { entry: %taddr = alloca <8 x i8>, align 8 store <8 x i8> , ptr %taddr, align 8 @@ -375,8 +355,7 @@ entry: ret i64 %0 } - -define void @test_f_vec_small_v1i64(i64 %0) #0 { +define void @test.f_vec_small_v1i64(i64 %0) #0 { entry: %x = alloca <1 x i64>, align 8 store i64 %0, ptr %x, align 8 @@ -386,8 +365,7 @@ entry: ret void } - -define i64 @test_f_vec_small_v1i64_ret() #0 { +define i64 @test.f_vec_small_v1i64_ret() #0 { entry: %taddr = alloca <1 x i64>, align 8 store <1 x i64> , ptr %taddr, align 8 @@ -395,8 +373,7 @@ entry: ret i64 %0 } - -define void @test_f_agg_small_aligned(i64 %0) #0 { +define void @test.f_agg_small_aligned(i64 %0) #0 { entry: %x = alloca %Small_aligned, align 8 store i64 %0, ptr %x, align 8 @@ -409,8 +386,7 @@ entry: ret void } - -define i64 @test_f_agg_small_aligned_ret(i64 %0) #0 { +define i64 @test.f_agg_small_aligned_ret(i64 %0) #0 { entry: %x = alloca %Small_aligned, align 8 %literal = alloca %Small_aligned, align 8 @@ -421,8 +397,7 @@ entry: ret i64 %2 } - -define void @test_f_agg_large(ptr align 4 %0) #0 { +define void @test.f_agg_large(ptr align 4 %0) #0 { entry: %1 = getelementptr inbounds %Large, ptr %0, i32 0, i32 0 %2 = getelementptr inbounds %Large, ptr %0, i32 0, i32 1 @@ -437,8 +412,7 @@ entry: ret void } - -define void @test_f_agg_large_ret(ptr noalias sret(%Large) align 4 %0, i32 %1, i8 signext %2) #0 { +define void @test.f_agg_large_ret(ptr noalias sret(%Large) align 4 %0, i32 %1, i8 signext %2) #0 { entry: %literal = alloca %Large, align 4 %3 = getelementptr inbounds %Large, ptr %literal, i32 0, i32 0 @@ -453,8 +427,7 @@ entry: ret void } - -define void @test_f_vec_large_v16i8(ptr align 16 %0) #0 { +define void @test.f_vec_large_v16i8(ptr align 16 %0) #0 { entry: %1 = load <16 x i8>, ptr %0, align 16 %2 = load <16 x i8>, ptr %0, align 16 @@ -464,15 +437,13 @@ entry: ret void } - -define void @test_f_vec_large_v16i8_ret(ptr noalias sret(<16 x i8>) align 16 %0) #0 { +define void @test.f_vec_large_v16i8_ret(ptr noalias sret(<16 x i8>) align 16 %0) #0 { entry: store <16 x i8> , ptr %0, align 16 ret void } - -define i32 @test_f_scalar_stack_1(i32 %0, [2 x i32] %1, i64 %2, ptr align 4 %3, i8 zeroext %4, i8 signext %5, i8 %6, i8 %7) #0 { +define i32 @test.f_scalar_stack_1(i32 %0, [2 x i32] %1, i64 %2, ptr align 4 %3, i8 zeroext %4, i8 signext %5, i8 %6, i8 %7) #0 { entry: %a = alloca %Tiny, align 1 %b = alloca %Small, align 4 @@ -486,8 +457,7 @@ entry: ret i32 %add } - -define void @test_f_scalar_stack_2(ptr noalias sret(%Large) align 4 %0, i32 %1, i64 %2, i64 %3, fp128 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { +define void @test.f_scalar_stack_2(ptr noalias sret(%Large) align 4 %0, i32 %1, i64 %2, i64 %3, fp128 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { entry: %literal = alloca %Large, align 4 %8 = getelementptr inbounds %Large, ptr %literal, i32 0, i32 0 @@ -505,18 +475,17 @@ entry: ret void } - -define fp128 @test_f_scalar_stack_4(i32 %0, i64 %1, i64 %2, fp128 %3, i8 zeroext %4, i8 %5, i8 %6) #0 { +define fp128 @test.f_scalar_stack_4(i32 %0, i64 %1, i64 %2, fp128 %3, i8 zeroext %4, i8 %5, i8 %6) #0 { entry: ret fp128 %3 } -define void @test_f_scalar_stack_5(double %0, i64 %1, double %2, i64 %3, i32 %4, i64 %5, float %6, double %7, fp128 %8) #0 { +define void @test.f_scalar_stack_5(double %0, i64 %1, double %2, i64 %3, i32 %4, i64 %5, float %6, double %7, fp128 %8) #0 { entry: ret void } -define void @test_f_agg_stack(double %0, i64 %1, double %2, i64 %3, i32 %4, [2 x i32] %5, i64 %6, ptr align 4 %7) #0 { +define void @test.f_agg_stack(double %0, i64 %1, double %2, i64 %3, i32 %4, [2 x i32] %5, i64 %6, ptr align 4 %7) #0 { entry: %e = alloca %Tiny, align 1 %f = alloca %Small, align 4 @@ -527,8 +496,7 @@ entry: ret void } - -define void @test_f_va_caller() #0 { +define void @test.f_va_caller() #0 { entry: %literal = alloca %Tiny, align 1 %literal1 = alloca %Small, align 4 @@ -563,4 +531,4 @@ entry: call void @llvm.memcpy.p0.p0.i32(ptr align 4 %indirectarg, ptr align 4 %literal3, i32 16, i1 false) %14 = call i32 (i32, ...) @f_va_callee(i32 1, i32 2, i32 3, double 4.000000e+00, double 5.000000e+00, i32 %4, [2 x i32] %7, i64 %9, ptr align 4 %indirectarg) ret void -} +} \ No newline at end of file diff --git a/test/test_suite/abi/riscv32-ilp32-ilp32f-ilp32d-abi-2.c3t b/test/test_suite/abi/riscv32-ilp32-ilp32f-ilp32d-abi-2.c3t index 85b711b4e..579897854 100644 --- a/test/test_suite/abi/riscv32-ilp32-ilp32f-ilp32d-abi-2.c3t +++ b/test/test_suite/abi/riscv32-ilp32-ilp32f-ilp32d-abi-2.c3t @@ -90,7 +90,6 @@ fn void f_vec_small_v1i64(long[<1>] x) { x[0] = 114; } -// CHECK-LABEL: define{{.*}} i64 @f_vec_small_v1i64_ret() fn long[<1>] f_vec_small_v1i64_ret() { return {1}; } @@ -116,7 +115,6 @@ struct Large { int a, b, c, d; } -// CHECK-LABEL: define{{.*}} void @f_agg_large(%struct.large* %x) fn void f_agg_large(Large x) { x.a = x.b + x.c + x.d; } @@ -182,71 +180,71 @@ fn void f_va_caller() { /* #expect: test.ll -define void @test_f_void() +define void @test.f_void() -define zeroext i8 @test_f_scalar_0(i8 zeroext %0) #0 { +define zeroext i8 @test.f_scalar_0(i8 zeroext %0) -define signext i8 @test_f_scalar_1(i8 signext %0) +define signext i8 @test.f_scalar_1(i8 signext %0) -define zeroext i8 @test_f_scalar_2(i8 zeroext %0) +define zeroext i8 @test.f_scalar_2(i8 zeroext %0) -define i32 @test_f_scalar_3(i32 %0) +define i32 @test.f_scalar_3(i32 %0) -define i64 @test_f_scalar_4(i64 %0) +define i64 @test.f_scalar_4(i64 %0) -define i128 @test_f_scalar_5(i128 %0) +define i128 @test.f_scalar_5(i128 %0) -define float @test_f_fp_scalar_1(float %0) +define float @test.f_fp_scalar_1(float %0) -define double @test_f_fp_scalar_2(double %0) +define double @test.f_fp_scalar_2(double %0) -define fp128 @test_f_fp_scalar_3(fp128 %0) +define fp128 @test.f_fp_scalar_3(fp128 %0) -define void @test_f_agg_tiny(i32 %0) +define void @test.f_agg_tiny(i32 %0) -define i32 @test_f_agg_tiny_ret() +define i32 @test.f_agg_tiny_ret() -define void @test_f_vec_tiny_v4i8(i32 %0) +define void @test.f_vec_tiny_v4i8(i32 %0) -define i32 @test_f_vec_tiny_v4i8_ret() +define i32 @test.f_vec_tiny_v4i8_ret() -define void @test_f_vec_tiny_v1i32(i32 %0) +define void @test.f_vec_tiny_v1i32(i32 %0) -define i32 @test_f_vec_tiny_v1i32_ret() +define i32 @test.f_vec_tiny_v1i32_ret() -define void @test_f_agg_small([2 x i32] %0) +define void @test.f_agg_small([2 x i32] %0) -define [2 x i32] @test_f_agg_small_ret() +define [2 x i32] @test.f_agg_small_ret() -define void @test_f_vec_small_v8i8(i64 %0) +define void @test.f_vec_small_v8i8(i64 %0) -define i64 @test_f_vec_small_v8i8_ret() +define i64 @test.f_vec_small_v8i8_ret() -define void @test_f_vec_small_v1i64(i64 %0) +define void @test.f_vec_small_v1i64(i64 %0) -define i64 @test_f_vec_small_v1i64_ret() +define i64 @test.f_vec_small_v1i64_ret() -define void @test_f_agg_small_aligned(i64 %0) +define void @test.f_agg_small_aligned(i64 %0) -define i64 @test_f_agg_small_aligned_ret(i64 %0) +define i64 @test.f_agg_small_aligned_ret(i64 %0) -define void @test_f_agg_large(ptr align 4 %0) +define void @test.f_agg_large(ptr align 4 %0) -define void @test_f_agg_large_ret(ptr noalias sret(%Large) align 4 %0, i32 %1, i8 signext %2) +define void @test.f_agg_large_ret(ptr noalias sret(%Large) align 4 %0, i32 %1, i8 signext %2) -define void @test_f_vec_large_v16i8(ptr align 16 %0) +define void @test.f_vec_large_v16i8(ptr align 16 %0) -define void @test_f_vec_large_v16i8_ret(ptr noalias sret(<16 x i8>) align 16 %0) +define void @test.f_vec_large_v16i8_ret(ptr noalias sret(<16 x i8>) align 16 %0) -define i32 @test_f_scalar_stack_1(i32 %0, [2 x i32] %1, i64 %2, ptr align 4 %3, i8 zeroext %4, i8 signext %5, i8 %6, i8 %7) +define i32 @test.f_scalar_stack_1(i32 %0, [2 x i32] %1, i64 %2, ptr align 4 %3, i8 zeroext %4, i8 signext %5, i8 %6, i8 %7) -define void @test_f_scalar_stack_2(ptr noalias sret(%Large) align 4 %0, i32 %1, i64 %2, i64 %3, fp128 %4, i8 zeroext %5, i8 %6, i8 %7) +define void @test.f_scalar_stack_2(ptr noalias sret(%Large) align 4 %0, i32 %1, i64 %2, i64 %3, fp128 %4, i8 zeroext %5, i8 %6, i8 %7) -define fp128 @test_f_scalar_stack_4(i32 %0, i64 %1, i64 %2, fp128 %3, i8 zeroext %4, i8 %5, i8 %6) +define fp128 @test.f_scalar_stack_4(i32 %0, i64 %1, i64 %2, fp128 %3, i8 zeroext %4, i8 %5, i8 %6) -define void @test_f_scalar_stack_5(double %0, i64 %1, double %2, i64 %3, i32 %4, i64 %5, float %6, double %7, fp128 %8) +define void @test.f_scalar_stack_5(double %0, i64 %1, double %2, i64 %3, i32 %4, i64 %5, float %6, double %7, fp128 %8) -define void @test_f_agg_stack(double %0, i64 %1, double %2, i64 %3, i32 %4, [2 x i32] %5, i64 %6, ptr align 4 %7) +define void @test.f_agg_stack(double %0, i64 %1, double %2, i64 %3, i32 %4, [2 x i32] %5, i64 %6, ptr align 4 %7) -define void @test_f_va_caller() +define void @test.f_va_caller() call i32 (i32, ...) @f_va_callee(i32 1, i32 2, i32 3, double 4.000000e+00, double 5.000000e+00, i32 %4, [2 x i32] %7, i64 %9, ptr align 4 %indirectarg) diff --git a/test/test_suite/abi/riscv32-ilp32-ilp32f-ilp32d-abi-3.c3t b/test/test_suite/abi/riscv32-ilp32-ilp32f-ilp32d-abi-3.c3t index c225cfe03..7f4a6e875 100644 --- a/test/test_suite/abi/riscv32-ilp32-ilp32f-ilp32d-abi-3.c3t +++ b/test/test_suite/abi/riscv32-ilp32-ilp32f-ilp32d-abi-3.c3t @@ -90,7 +90,6 @@ fn void f_vec_small_v1i64(long[<1>] x) { x[0] = 114; } -// CHECK-LABEL: define{{.*}} i64 @f_vec_small_v1i64_ret() fn long[<1>] f_vec_small_v1i64_ret() { return {1}; } @@ -116,7 +115,6 @@ struct Large { int a, b, c, d; } -// CHECK-LABEL: define{{.*}} void @f_agg_large(%struct.large* %x) fn void f_agg_large(Large x) { x.a = x.b + x.c + x.d; } @@ -182,71 +180,71 @@ fn void f_va_caller() { /* #expect: test.ll -define void @test_f_void() +define void @test.f_void() -define zeroext i8 @test_f_scalar_0(i8 zeroext %0) #0 { +define zeroext i8 @test.f_scalar_0(i8 zeroext %0) #0 { -define signext i8 @test_f_scalar_1(i8 signext %0) +define signext i8 @test.f_scalar_1(i8 signext %0) -define zeroext i8 @test_f_scalar_2(i8 zeroext %0) +define zeroext i8 @test.f_scalar_2(i8 zeroext %0) -define i32 @test_f_scalar_3(i32 %0) +define i32 @test.f_scalar_3(i32 %0) -define i64 @test_f_scalar_4(i64 %0) +define i64 @test.f_scalar_4(i64 %0) -define i128 @test_f_scalar_5(i128 %0) +define i128 @test.f_scalar_5(i128 %0) -define float @test_f_fp_scalar_1(float %0) +define float @test.f_fp_scalar_1(float %0) -define double @test_f_fp_scalar_2(double %0) +define double @test.f_fp_scalar_2(double %0) -define fp128 @test_f_fp_scalar_3(fp128 %0) +define fp128 @test.f_fp_scalar_3(fp128 %0) -define void @test_f_agg_tiny(i32 %0) +define void @test.f_agg_tiny(i32 %0) -define i32 @test_f_agg_tiny_ret() +define i32 @test.f_agg_tiny_ret() -define void @test_f_vec_tiny_v4i8(i32 %0) +define void @test.f_vec_tiny_v4i8(i32 %0) -define i32 @test_f_vec_tiny_v4i8_ret() +define i32 @test.f_vec_tiny_v4i8_ret() -define void @test_f_vec_tiny_v1i32(i32 %0) +define void @test.f_vec_tiny_v1i32(i32 %0) -define i32 @test_f_vec_tiny_v1i32_ret() +define i32 @test.f_vec_tiny_v1i32_ret() -define void @test_f_agg_small([2 x i32] %0) +define void @test.f_agg_small([2 x i32] %0) -define [2 x i32] @test_f_agg_small_ret() +define [2 x i32] @test.f_agg_small_ret() -define void @test_f_vec_small_v8i8(i64 %0) +define void @test.f_vec_small_v8i8(i64 %0) -define i64 @test_f_vec_small_v8i8_ret() +define i64 @test.f_vec_small_v8i8_ret() -define void @test_f_vec_small_v1i64(i64 %0) +define void @test.f_vec_small_v1i64(i64 %0) -define i64 @test_f_vec_small_v1i64_ret() +define i64 @test.f_vec_small_v1i64_ret() -define void @test_f_agg_small_aligned(i64 %0) +define void @test.f_agg_small_aligned(i64 %0) -define i64 @test_f_agg_small_aligned_ret(i64 %0) +define i64 @test.f_agg_small_aligned_ret(i64 %0) -define void @test_f_agg_large(ptr align 4 %0) +define void @test.f_agg_large(ptr align 4 %0) -define void @test_f_agg_large_ret(ptr noalias sret(%Large) align 4 %0, i32 %1, i8 signext %2) +define void @test.f_agg_large_ret(ptr noalias sret(%Large) align 4 %0, i32 %1, i8 signext %2) -define void @test_f_vec_large_v16i8(ptr align 16 %0) +define void @test.f_vec_large_v16i8(ptr align 16 %0) -define void @test_f_vec_large_v16i8_ret(ptr noalias sret(<16 x i8>) align 16 %0) +define void @test.f_vec_large_v16i8_ret(ptr noalias sret(<16 x i8>) align 16 %0) -define i32 @test_f_scalar_stack_1(i32 %0, [2 x i32] %1, i64 %2, ptr align 4 %3, i8 zeroext %4, i8 signext %5, i8 %6, i8 %7) +define i32 @test.f_scalar_stack_1(i32 %0, [2 x i32] %1, i64 %2, ptr align 4 %3, i8 zeroext %4, i8 signext %5, i8 %6, i8 %7) -define void @test_f_scalar_stack_2(ptr noalias sret(%Large) align 4 %0, i32 %1, i64 %2, i64 %3, fp128 %4, i8 zeroext %5, i8 %6, i8 %7) +define void @test.f_scalar_stack_2(ptr noalias sret(%Large) align 4 %0, i32 %1, i64 %2, i64 %3, fp128 %4, i8 zeroext %5, i8 %6, i8 %7) -define fp128 @test_f_scalar_stack_4(i32 %0, i64 %1, i64 %2, fp128 %3, i8 zeroext %4, i8 %5, i8 %6) +define fp128 @test.f_scalar_stack_4(i32 %0, i64 %1, i64 %2, fp128 %3, i8 zeroext %4, i8 %5, i8 %6) -define void @test_f_scalar_stack_5(double %0, i64 %1, double %2, i64 %3, i32 %4, i64 %5, float %6, double %7, fp128 %8) +define void @test.f_scalar_stack_5(double %0, i64 %1, double %2, i64 %3, i32 %4, i64 %5, float %6, double %7, fp128 %8) -define void @test_f_agg_stack(double %0, i64 %1, double %2, i64 %3, i32 %4, [2 x i32] %5, i64 %6, ptr align 4 %7) +define void @test.f_agg_stack(double %0, i64 %1, double %2, i64 %3, i32 %4, [2 x i32] %5, i64 %6, ptr align 4 %7) -define void @test_f_va_caller() +define void @test.f_va_caller() call i32 (i32, ...) @f_va_callee(i32 1, i32 2, i32 3, double 4.000000e+00, double 5.000000e+00, i32 %4, [2 x i32] %7, i64 %9, ptr align 4 %indirectarg) diff --git a/test/test_suite/abi/riscv32-ilp32d-abi.c3t b/test/test_suite/abi/riscv32-ilp32d-abi.c3t index 30bf3384a..3a80c2e21 100644 --- a/test/test_suite/abi/riscv32-ilp32d-abi.c3t +++ b/test/test_suite/abi/riscv32-ilp32d-abi.c3t @@ -175,13 +175,13 @@ fn Double_double_s f_ret_double_double_s_double_int32_s_just_sufficient_gprs( /* #expect: test.ll -define void @test_f_fpr_tracking(double %0, double %1, double %2, double %3, double %4, double %5, double %6, double %7, i8 zeroext %8) #0 { +define void @test.f_fpr_tracking(double %0, double %1, double %2, double %3, double %4, double %5, double %6, double %7, i8 zeroext %8) #0 { entry: ret void } -define void @test_f_double_s_arg(double %0) #0 { +define void @test.f_double_s_arg(double %0) #0 { entry: %a = alloca %Double_s, align 8 store double %0, ptr %a, align 8 @@ -189,7 +189,7 @@ entry: } -define double @test_f_ret_double_s() #0 { +define double @test.f_ret_double_s() #0 { entry: %literal = alloca %Double_s, align 8 %0 = getelementptr inbounds %Double_s, ptr %literal, i32 0, i32 0 @@ -199,7 +199,7 @@ entry: } -define void @test_f_double_double_s_arg(double %0, double %1) #0 { +define void @test.f_double_double_s_arg(double %0, double %1) #0 { entry: %a = alloca %Double_double_s, align 8 store double %0, ptr %a, align 8 @@ -209,7 +209,7 @@ entry: } -define { double, double } @test_f_ret_double_double_s() #0 { +define { double, double } @test.f_ret_double_double_s() #0 { entry: %literal = alloca %Double_double_s, align 8 %0 = getelementptr inbounds %Double_double_s, ptr %literal, i32 0, i32 0 @@ -225,7 +225,7 @@ entry: } -define void @test_f_double_float_s_arg(double %0, float %1) #0 { +define void @test.f_double_float_s_arg(double %0, float %1) #0 { entry: %a = alloca %Double_float_s, align 8 store double %0, ptr %a, align 8 @@ -235,7 +235,7 @@ entry: } -define { double, float } @test_f_ret_double_float_s() #0 { +define { double, float } @test.f_ret_double_float_s() #0 { entry: %literal = alloca %Double_float_s, align 8 %0 = getelementptr inbounds %Double_float_s, ptr %literal, i32 0, i32 0 @@ -251,13 +251,13 @@ entry: } -define void @test_f_double_double_s_arg_insufficient_fprs(float %0, double %1, double %2, double %3, double %4, double %5, double %6, ptr align 8 %7) #0 { +define void @test.f_double_double_s_arg_insufficient_fprs(float %0, double %1, double %2, double %3, double %4, double %5, double %6, ptr align 8 %7) #0 { entry: ret void } -define void @test_f_double_int8_s_arg(double %0, i8 %1) #0 { +define void @test.f_double_int8_s_arg(double %0, i8 %1) #0 { entry: %a = alloca %Double_int8_s, align 8 store double %0, ptr %a, align 8 @@ -267,7 +267,7 @@ entry: } -define { double, i8 } @test_f_ret_double_int8_s() #0 { +define { double, i8 } @test.f_ret_double_int8_s() #0 { entry: %literal = alloca %Double_int8_s, align 8 %0 = getelementptr inbounds %Double_int8_s, ptr %literal, i32 0, i32 0 @@ -283,7 +283,7 @@ entry: } -define void @test_f_double_uint8_s_arg(double %0, i8 %1) #0 { +define void @test.f_double_uint8_s_arg(double %0, i8 %1) #0 { entry: %a = alloca %Double_uint8_s, align 8 store double %0, ptr %a, align 8 @@ -293,7 +293,7 @@ entry: } -define { double, i8 } @test_f_ret_double_uint8_s() #0 { +define { double, i8 } @test.f_ret_double_uint8_s() #0 { entry: %literal = alloca %Double_uint8_s, align 8 %0 = getelementptr inbounds %Double_uint8_s, ptr %literal, i32 0, i32 0 @@ -309,7 +309,7 @@ entry: } -define void @test_f_double_int32_s_arg(double %0, i32 %1) #0 { +define void @test.f_double_int32_s_arg(double %0, i32 %1) #0 { entry: %a = alloca %Double_int32_s, align 8 store double %0, ptr %a, align 8 @@ -319,7 +319,7 @@ entry: } -define { double, i32 } @test_f_ret_double_int32_s() #0 { +define { double, i32 } @test.f_ret_double_int32_s() #0 { entry: %literal = alloca %Double_int32_s, align 8 %0 = getelementptr inbounds %Double_int32_s, ptr %literal, i32 0, i32 0 @@ -335,13 +335,13 @@ entry: } -define void @test_f_double_int64_s_arg(ptr align 8 %0) #0 { +define void @test.f_double_int64_s_arg(ptr align 8 %0) #0 { entry: ret void } -define void @test_f_ret_double_int64_s(ptr noalias sret(%Double_int64_s) align 8 %0) #0 { +define void @test.f_ret_double_int64_s(ptr noalias sret(%Double_int64_s) align 8 %0) #0 { entry: %literal = alloca %Double_int64_s, align 8 %1 = getelementptr inbounds %Double_int64_s, ptr %literal, i32 0, i32 0 @@ -353,19 +353,19 @@ entry: } -define void @test_f_double_int8_s_arg_insufficient_gprs(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6, i32 %7, ptr align 8 %8) #0 { +define void @test.f_double_int8_s_arg_insufficient_gprs(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6, i32 %7, ptr align 8 %8) #0 { entry: ret void } -define void @test_f_struct_double_int8_insufficient_fprs(float %0, double %1, double %2, double %3, double %4, double %5, double %6, double %7, ptr align 8 %8) #0 { +define void @test.f_struct_double_int8_insufficient_fprs(float %0, double %1, double %2, double %3, double %4, double %5, double %6, double %7, ptr align 8 %8) #0 { entry: ret void } -define void @test_f_doublearr1_s_arg(double %0) #0 { +define void @test.f_doublearr1_s_arg(double %0) #0 { entry: %a = alloca %Doublearr1_s, align 8 store double %0, ptr %a, align 8 @@ -373,7 +373,7 @@ entry: } -define double @test_f_ret_doublearr1_s() #0 { +define double @test.f_ret_doublearr1_s() #0 { entry: %literal = alloca %Doublearr1_s, align 8 %0 = getelementptr inbounds %Doublearr1_s, ptr %literal, i32 0, i32 0 @@ -384,7 +384,7 @@ entry: } -define void @test_f_doublearr2_s_arg(double %0, double %1) #0 { +define void @test.f_doublearr2_s_arg(double %0, double %1) #0 { entry: %a = alloca %Doublearr2_s, align 8 store double %0, ptr %a, align 8 @@ -394,7 +394,7 @@ entry: } -define { double, double } @test_f_ret_doublearr2_s() #0 { +define { double, double } @test.f_ret_doublearr2_s() #0 { entry: %literal = alloca %Doublearr2_s, align 8 %0 = getelementptr inbounds %Doublearr2_s, ptr %literal, i32 0, i32 0 @@ -411,7 +411,7 @@ entry: } -define void @test_f_doublearr2_tricky1_s_arg(double %0, double %1) #0 { +define void @test.f_doublearr2_tricky1_s_arg(double %0, double %1) #0 { entry: %a = alloca %Doublearr2_tricky1_s, align 8 store double %0, ptr %a, align 8 @@ -421,7 +421,7 @@ entry: } -define { double, double } @test_f_ret_doublearr2_tricky1_s() #0 { +define { double, double } @test.f_ret_doublearr2_tricky1_s() #0 { entry: %literal = alloca %Doublearr2_tricky1_s, align 8 %0 = getelementptr inbounds %Doublearr2_tricky1_s, ptr %literal, i32 0, i32 0 @@ -442,13 +442,13 @@ entry: } -define void @test_f_int_double_int_s_arg(ptr align 8 %0) #0 { +define void @test.f_int_double_int_s_arg(ptr align 8 %0) #0 { entry: ret void } -define void @test_f_ret_int_double_int_s(ptr noalias sret(%Int_double_int_s) align 8 %0) #0 { +define void @test.f_ret_int_double_int_s(ptr noalias sret(%Int_double_int_s) align 8 %0) #0 { entry: %literal = alloca %Int_double_int_s, align 8 %1 = getelementptr inbounds %Int_double_int_s, ptr %literal, i32 0, i32 0 @@ -462,13 +462,13 @@ entry: } -define void @test_f_int64_double_s_arg(ptr align 8 %0) #0 { +define void @test.f_int64_double_s_arg(ptr align 8 %0) #0 { entry: ret void } -define void @test_f_ret_int64_double_s(ptr noalias sret(%Int64_double_s) align 8 %0) #0 { +define void @test.f_ret_int64_double_s(ptr noalias sret(%Int64_double_s) align 8 %0) #0 { entry: %literal = alloca %Int64_double_s, align 8 %1 = getelementptr inbounds %Int64_double_s, ptr %literal, i32 0, i32 0 @@ -480,13 +480,13 @@ entry: } -define void @test_f_char_char_double_s_arg(ptr align 8 %0) #0 { +define void @test.f_char_char_double_s_arg(ptr align 8 %0) #0 { entry: ret void } -define void @test_f_ret_char_char_double_s(ptr noalias sret(%Char_char_double_s) align 8 %0) #0 { +define void @test.f_ret_char_char_double_s(ptr noalias sret(%Char_char_double_s) align 8 %0) #0 { entry: %literal = alloca %Char_char_double_s, align 8 %1 = getelementptr inbounds %Char_char_double_s, ptr %literal, i32 0, i32 0 @@ -500,7 +500,7 @@ entry: } -define void @test_f_double_u_arg(i64 %0) #0 { +define void @test.f_double_u_arg(i64 %0) #0 { entry: %a = alloca %Double_u, align 8 store i64 %0, ptr %a, align 8 @@ -508,7 +508,7 @@ entry: } -define i64 @test_f_ret_double_u() #0 { +define i64 @test.f_ret_double_u() #0 { entry: %literal = alloca %Double_u, align 8 store double 1.000000e+00, ptr %literal, align 8 @@ -517,7 +517,7 @@ entry: } -define { double, i32 } @test_f_ret_double_int32_s_double_int32_s_just_sufficient_gprs(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6, double %7, i32 %8) #0 { +define { double, i32 } @test.f_ret_double_int32_s_double_int32_s_just_sufficient_gprs(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6, double %7, i32 %8) #0 { entry: %h = alloca %Double_int32_s, align 8 %literal = alloca %Double_int32_s, align 8 @@ -537,7 +537,7 @@ entry: } -define { double, double } @test_f_ret_double_double_s_double_int32_s_just_sufficient_gprs(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6, double %7, i32 %8) #0 { +define { double, double } @test.f_ret_double_double_s_double_int32_s_just_sufficient_gprs(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6, double %7, i32 %8) #0 { entry: %h = alloca %Double_int32_s, align 8 %literal = alloca %Double_double_s, align 8 diff --git a/test/test_suite/abi/riscv32-ilp32f-abi.c3t b/test/test_suite/abi/riscv32-ilp32f-abi.c3t index 06658dbc8..c2f35874d 100644 --- a/test/test_suite/abi/riscv32-ilp32f-abi.c3t +++ b/test/test_suite/abi/riscv32-ilp32f-abi.c3t @@ -35,13 +35,13 @@ fn Int_double_s f_ret_int_double_s() { /* #expect: test.ll -define void @test_f_fpr_tracking(double %0, double %1, double %2, double %3, i8 %4) #0 { +define void @test.f_fpr_tracking(double %0, double %1, double %2, double %3, i8 %4) #0 { entry: ret void } -define void @test_f_double_s_arg(i64 %0) #0 { +define void @test.f_double_s_arg(i64 %0) #0 { entry: %a = alloca %Double_s, align 8 store i64 %0, ptr %a, align 8 @@ -49,7 +49,7 @@ entry: } -define i64 @test_f_ret_double_s() #0 { +define i64 @test.f_ret_double_s() #0 { entry: %literal = alloca %Double_s, align 8 %0 = getelementptr inbounds %Double_s, ptr %literal, i32 0, i32 0 @@ -59,13 +59,13 @@ entry: } -define void @test_f_double_double_s_arg(ptr align 8 %0) #0 { +define void @test.f_double_double_s_arg(ptr align 8 %0) #0 { entry: ret void } -define void @test_f_ret_double_double_s(ptr noalias sret(%Double_double_s) align 8 %0) #0 { +define void @test.f_ret_double_double_s(ptr noalias sret(%Double_double_s) align 8 %0) #0 { entry: %literal = alloca %Double_double_s, align 8 %1 = getelementptr inbounds %Double_double_s, ptr %literal, i32 0, i32 0 @@ -77,13 +77,13 @@ entry: } -define void @test_f_int_double_s_arg(ptr align 8 %0) #0 { +define void @test.f_int_double_s_arg(ptr align 8 %0) #0 { entry: ret void } -define void @test_f_ret_int_double_s(ptr noalias sret(%Int_double_s) align 8 %0) #0 { +define void @test.f_ret_int_double_s(ptr noalias sret(%Int_double_s) align 8 %0) #0 { entry: %literal = alloca %Int_double_s, align 8 %1 = getelementptr inbounds %Int_double_s, ptr %literal, i32 0, i32 0 diff --git a/test/test_suite/abi/riscv32-ilp32f-ilp32d-abi-1.c3t b/test/test_suite/abi/riscv32-ilp32f-ilp32d-abi-1.c3t index 040bf94c2..cf407ed12 100644 --- a/test/test_suite/abi/riscv32-ilp32f-ilp32d-abi-1.c3t +++ b/test/test_suite/abi/riscv32-ilp32f-ilp32d-abi-1.c3t @@ -153,48 +153,48 @@ fn Float_u f_ret_float_u() { /* #expect: test.ll -define void @test_f_fpr_tracking(float %0, float %1, float %2, float %3, float %4, float %5, float %6, float %7, i8 zeroext %8) +define void @test.f_fpr_tracking(float %0, float %1, float %2, float %3, float %4, float %5, float %6, float %7, i8 zeroext %8) -define void @test_f_float_s_arg(float %0) -define float @test_f_ret_float_s() +define void @test.f_float_s_arg(float %0) +define float @test.f_ret_float_s() -define void @test_f_float_float_s_arg(float %0, float %1) -define { float, float } @test_f_ret_float_float_s() +define void @test.f_float_float_s_arg(float %0, float %1) +define { float, float } @test.f_ret_float_float_s() -define void @test_f_float_float_s_arg_insufficient_fprs(float %0, float %1, float %2, float %3, float %4, float %5, float %6, [2 x i32] %7) #0 { +define void @test.f_float_float_s_arg_insufficient_fprs(float %0, float %1, float %2, float %3, float %4, float %5, float %6, [2 x i32] %7) #0 { -define void @test_f_float_int8_s_arg(float %0, i8 %1) -define { float, i8 } @test_f_ret_float_int8_s() +define void @test.f_float_int8_s_arg(float %0, i8 %1) +define { float, i8 } @test.f_ret_float_int8_s() -define void @test_f_float_uint8_s_arg(float %0, i8 %1) -define { float, i8 } @test_f_ret_float_uint8_s() +define void @test.f_float_uint8_s_arg(float %0, i8 %1) +define { float, i8 } @test.f_ret_float_uint8_s() -define void @test_f_float_int32_s_arg(float %0, i32 %1) -define { float, i32 } @test_f_ret_float_int32_s() +define void @test.f_float_int32_s_arg(float %0, i32 %1) +define { float, i32 } @test.f_ret_float_int32_s() -define void @test_f_float_int64_s_arg(ptr align 8 %0) -define void @test_f_ret_float_int64_s(ptr noalias sret(%Float_int64_s) align 8 %0) +define void @test.f_float_int64_s_arg(ptr align 8 %0) +define void @test.f_ret_float_int64_s(ptr noalias sret(%Float_int64_s) align 8 %0) -define void @test_f_float_int8_s_arg_insufficient_gprs(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6, i32 %7, [2 x i32] %8) -define void @test_f_struct_float_int8_insufficient_fprs(float %0, float %1, float %2, float %3, float %4, float %5, float %6, float %7, [2 x i32] %8) +define void @test.f_float_int8_s_arg_insufficient_gprs(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6, i32 %7, [2 x i32] %8) +define void @test.f_struct_float_int8_insufficient_fprs(float %0, float %1, float %2, float %3, float %4, float %5, float %6, float %7, [2 x i32] %8) -define void @test_f_floatarr1_s_arg(float %0) -define float @test_f_ret_floatarr1_s() +define void @test.f_floatarr1_s_arg(float %0) +define float @test.f_ret_floatarr1_s() -define void @test_f_floatarr2_s_arg(float %0, float %1) -define { float, float } @test_f_ret_floatarr2_s() +define void @test.f_floatarr2_s_arg(float %0, float %1) +define { float, float } @test.f_ret_floatarr2_s() -define void @test_f_floatarr2_tricky1_s_arg(float %0, float %1) -define { float, float } @test_f_ret_floatarr2_tricky1_s() +define void @test.f_floatarr2_tricky1_s_arg(float %0, float %1) +define { float, float } @test.f_ret_floatarr2_tricky1_s() -define void @test_f_int_float_int_s_arg(ptr align 4 %0) -define void @test_f_ret_int_float_int_s(ptr noalias sret(%Int_float_int_s) align 4 %0) +define void @test.f_int_float_int_s_arg(ptr align 4 %0) +define void @test.f_ret_int_float_int_s(ptr noalias sret(%Int_float_int_s) align 4 %0) -define void @test_f_int64_float_s_arg(ptr align 8 %0) -define void @test_f_ret_int64_float_s(ptr noalias sret(%Int64_float_s) align 8 %0) +define void @test.f_int64_float_s_arg(ptr align 8 %0) +define void @test.f_ret_int64_float_s(ptr noalias sret(%Int64_float_s) align 8 %0) -define void @test_f_char_char_float_s_arg([2 x i32] %0) -define [2 x i32] @test_f_ret_char_char_float_s() +define void @test.f_char_char_float_s_arg([2 x i32] %0) +define [2 x i32] @test.f_ret_char_char_float_s() -define void @test_f_float_u_arg(i32 %0) -define i32 @test_f_ret_float_u() \ No newline at end of file +define void @test.f_float_u_arg(i32 %0) +define i32 @test.f_ret_float_u() \ No newline at end of file diff --git a/test/test_suite/abi/riscv32-ilp32f-ilp32d-abi-2.c3t b/test/test_suite/abi/riscv32-ilp32f-ilp32d-abi-2.c3t index fd606ed09..d45407b98 100644 --- a/test/test_suite/abi/riscv32-ilp32f-ilp32d-abi-2.c3t +++ b/test/test_suite/abi/riscv32-ilp32f-ilp32d-abi-2.c3t @@ -153,19 +153,19 @@ fn Float_u f_ret_float_u() { /* #expect: test.ll -define void @test_f_fpr_tracking(float %0, float %1, float %2, float %3, float %4, float %5, float %6, float %7, i8 zeroext %8) #0 { +define void @test.f_fpr_tracking(float %0, float %1, float %2, float %3, float %4, float %5, float %6, float %7, i8 zeroext %8) #0 { entry: ret void } -define void @test_f_float_s_arg(float %0) #0 { +define void @test.f_float_s_arg(float %0) #0 { entry: %a = alloca %Float_s, align 4 store float %0, ptr %a, align 4 ret void } -define float @test_f_ret_float_s() #0 { +define float @test.f_ret_float_s() #0 { entry: %literal = alloca %Float_s, align 4 %0 = getelementptr inbounds %Float_s, ptr %literal, i32 0, i32 0 @@ -174,7 +174,7 @@ entry: ret float %1 } -define void @test_f_float_float_s_arg(float %0, float %1) #0 { +define void @test.f_float_float_s_arg(float %0, float %1) #0 { entry: %a = alloca %Float_float_s, align 4 store float %0, ptr %a, align 4 @@ -183,7 +183,7 @@ entry: ret void } -define { float, float } @test_f_ret_float_float_s() #0 { +define { float, float } @test.f_ret_float_float_s() #0 { entry: %literal = alloca %Float_float_s, align 4 %0 = getelementptr inbounds %Float_float_s, ptr %literal, i32 0, i32 0 @@ -198,14 +198,14 @@ entry: ret { float, float } %5 } -define void @test_f_float_float_s_arg_insufficient_fprs(float %0, float %1, float %2, float %3, float %4, float %5, float %6, [2 x i32] %7) #0 { +define void @test.f_float_float_s_arg_insufficient_fprs(float %0, float %1, float %2, float %3, float %4, float %5, float %6, [2 x i32] %7) #0 { entry: %h = alloca %Float_float_s, align 4 store [2 x i32] %7, ptr %h, align 4 ret void } -define void @test_f_float_int8_s_arg(float %0, i8 %1) #0 { +define void @test.f_float_int8_s_arg(float %0, i8 %1) #0 { entry: %a = alloca %Float_int8_s, align 4 store float %0, ptr %a, align 4 @@ -214,7 +214,7 @@ entry: ret void } -define { float, i8 } @test_f_ret_float_int8_s() #0 { +define { float, i8 } @test.f_ret_float_int8_s() #0 { entry: %literal = alloca %Float_int8_s, align 4 %0 = getelementptr inbounds %Float_int8_s, ptr %literal, i32 0, i32 0 @@ -229,7 +229,7 @@ entry: ret { float, i8 } %5 } -define void @test_f_float_uint8_s_arg(float %0, i8 %1) #0 { +define void @test.f_float_uint8_s_arg(float %0, i8 %1) #0 { entry: %a = alloca %Float_uint8_s, align 4 store float %0, ptr %a, align 4 @@ -238,7 +238,7 @@ entry: ret void } -define { float, i8 } @test_f_ret_float_uint8_s() #0 { +define { float, i8 } @test.f_ret_float_uint8_s() #0 { entry: %literal = alloca %Float_uint8_s, align 4 %0 = getelementptr inbounds %Float_uint8_s, ptr %literal, i32 0, i32 0 @@ -253,7 +253,7 @@ entry: ret { float, i8 } %5 } -define void @test_f_float_int32_s_arg(float %0, i32 %1) #0 { +define void @test.f_float_int32_s_arg(float %0, i32 %1) #0 { entry: %a = alloca %Float_int32_s, align 4 store float %0, ptr %a, align 4 @@ -262,7 +262,7 @@ entry: ret void } -define { float, i32 } @test_f_ret_float_int32_s() #0 { +define { float, i32 } @test.f_ret_float_int32_s() #0 { entry: %literal = alloca %Float_int32_s, align 4 %0 = getelementptr inbounds %Float_int32_s, ptr %literal, i32 0, i32 0 @@ -277,12 +277,12 @@ entry: ret { float, i32 } %5 } -define void @test_f_float_int64_s_arg(ptr align 8 %0) #0 { +define void @test.f_float_int64_s_arg(ptr align 8 %0) #0 { entry: ret void } -define void @test_f_ret_float_int64_s(ptr noalias sret(%Float_int64_s) align 8 %0) #0 { +define void @test.f_ret_float_int64_s(ptr noalias sret(%Float_int64_s) align 8 %0) #0 { entry: %literal = alloca %Float_int64_s, align 8 %1 = getelementptr inbounds %Float_int64_s, ptr %literal, i32 0, i32 0 @@ -293,28 +293,28 @@ entry: ret void } -define void @test_f_float_int8_s_arg_insufficient_gprs(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6, i32 %7, [2 x i32] %8) #0 { +define void @test.f_float_int8_s_arg_insufficient_gprs(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6, i32 %7, [2 x i32] %8) #0 { entry: %i = alloca %Float_int8_s, align 4 store [2 x i32] %8, ptr %i, align 4 ret void } -define void @test_f_struct_float_int8_insufficient_fprs(float %0, float %1, float %2, float %3, float %4, float %5, float %6, float %7, [2 x i32] %8) #0 { +define void @test.f_struct_float_int8_insufficient_fprs(float %0, float %1, float %2, float %3, float %4, float %5, float %6, float %7, [2 x i32] %8) #0 { entry: %i = alloca %Float_int8_s, align 4 store [2 x i32] %8, ptr %i, align 4 ret void } -define void @test_f_floatarr1_s_arg(float %0) #0 { +define void @test.f_floatarr1_s_arg(float %0) #0 { entry: %a = alloca %Floatarr1_s, align 4 store float %0, ptr %a, align 4 ret void } -define float @test_f_ret_floatarr1_s() #0 { +define float @test.f_ret_floatarr1_s() #0 { entry: %literal = alloca %Floatarr1_s, align 4 %0 = getelementptr inbounds %Floatarr1_s, ptr %literal, i32 0, i32 0 @@ -324,7 +324,7 @@ entry: ret float %2 } -define void @test_f_floatarr2_s_arg(float %0, float %1) #0 { +define void @test.f_floatarr2_s_arg(float %0, float %1) #0 { entry: %a = alloca %Floatarr2_s, align 4 store float %0, ptr %a, align 4 @@ -333,7 +333,7 @@ entry: ret void } -define { float, float } @test_f_ret_floatarr2_s() #0 { +define { float, float } @test.f_ret_floatarr2_s() #0 { entry: %literal = alloca %Floatarr2_s, align 4 %0 = getelementptr inbounds %Floatarr2_s, ptr %literal, i32 0, i32 0 @@ -349,7 +349,7 @@ entry: ret { float, float } %6 } -define void @test_f_floatarr2_tricky1_s_arg(float %0, float %1) #0 { +define void @test.f_floatarr2_tricky1_s_arg(float %0, float %1) #0 { entry: %a = alloca %Floatarr2_tricky1_s, align 4 store float %0, ptr %a, align 4 @@ -358,7 +358,7 @@ entry: ret void } -define { float, float } @test_f_ret_floatarr2_tricky1_s() #0 { +define { float, float } @test.f_ret_floatarr2_tricky1_s() #0 { entry: %literal = alloca %Floatarr2_tricky1_s, align 4 %0 = getelementptr inbounds %Floatarr2_tricky1_s, ptr %literal, i32 0, i32 0 @@ -378,12 +378,12 @@ entry: ret { float, float } %10 } -define void @test_f_int_float_int_s_arg(ptr align 4 %0) #0 { +define void @test.f_int_float_int_s_arg(ptr align 4 %0) #0 { entry: ret void } -define void @test_f_ret_int_float_int_s(ptr noalias sret(%Int_float_int_s) align 4 %0) #0 { +define void @test.f_ret_int_float_int_s(ptr noalias sret(%Int_float_int_s) align 4 %0) #0 { entry: %literal = alloca %Int_float_int_s, align 4 %1 = getelementptr inbounds %Int_float_int_s, ptr %literal, i32 0, i32 0 @@ -396,12 +396,12 @@ entry: ret void } -define void @test_f_int64_float_s_arg(ptr align 8 %0) #0 { +define void @test.f_int64_float_s_arg(ptr align 8 %0) #0 { entry: ret void } -define void @test_f_ret_int64_float_s(ptr noalias sret(%Int64_float_s) align 8 %0) #0 { +define void @test.f_ret_int64_float_s(ptr noalias sret(%Int64_float_s) align 8 %0) #0 { entry: %literal = alloca %Int64_float_s, align 8 %1 = getelementptr inbounds %Int64_float_s, ptr %literal, i32 0, i32 0 @@ -412,14 +412,14 @@ entry: ret void } -define void @test_f_char_char_float_s_arg([2 x i32] %0) #0 { +define void @test.f_char_char_float_s_arg([2 x i32] %0) #0 { entry: %a = alloca %Char_char_float_s, align 4 store [2 x i32] %0, ptr %a, align 4 ret void } -define [2 x i32] @test_f_ret_char_char_float_s() #0 { +define [2 x i32] @test.f_ret_char_char_float_s() #0 { entry: %literal = alloca %Char_char_float_s, align 4 %0 = getelementptr inbounds %Char_char_float_s, ptr %literal, i32 0, i32 0 @@ -432,14 +432,14 @@ entry: ret [2 x i32] %3 } -define void @test_f_float_u_arg(i32 %0) #0 { +define void @test.f_float_u_arg(i32 %0) #0 { entry: %a = alloca %Float_u, align 4 store i32 %0, ptr %a, align 4 ret void } -define i32 @test_f_ret_float_u() #0 { +define i32 @test.f_ret_float_u() #0 { entry: %literal = alloca %Float_u, align 4 store float 1.000000e+00, ptr %literal, align 4 diff --git a/test/test_suite/abi/riscv64-lp64-abi.c3t b/test/test_suite/abi/riscv64-lp64-abi.c3t index b2df61d82..a3e796980 100644 --- a/test/test_suite/abi/riscv64-lp64-abi.c3t +++ b/test/test_suite/abi/riscv64-lp64-abi.c3t @@ -19,14 +19,14 @@ fn Large f_scalar_stack_2(double a, int128 b, float128 c, V32i8 d, /* #expect: test.ll -define signext i32 @test_f_scalar_stack_1(i32 signext %0, i128 %1, float %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) +define signext i32 @test.f_scalar_stack_1(i32 signext %0, i128 %1, float %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) entry: %uisiext = zext i8 %6 to i32 %uisiext1 = zext i8 %7 to i32 %add = add i32 %uisiext, %uisiext1 ret i32 %add -define void @test_f_scalar_stack_2(ptr noalias sret(%Large) align 8 %0, double %1, i128 %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) +define void @test.f_scalar_stack_2(ptr noalias sret(%Large) align 8 %0, double %1, i128 %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) entry: %literal = alloca %Large, align 8 %8 = getelementptr inbounds %Large, ptr %literal, i32 0, i32 0 diff --git a/test/test_suite/abi/riscv64-lp64-lp64f-abi-1.c3t b/test/test_suite/abi/riscv64-lp64-lp64f-abi-1.c3t index 38f20c9b1..913d2f143 100644 --- a/test/test_suite/abi/riscv64-lp64-lp64f-abi-1.c3t +++ b/test/test_suite/abi/riscv64-lp64-lp64f-abi-1.c3t @@ -23,7 +23,7 @@ fn Large f_scalar_stack_2(double a, int128 b, float128 c, char[<32>] d, /* #expect: test.ll -define signext i32 @test_f_scalar_stack_1(i32 signext %0, i128 %1, double %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { +define signext i32 @test.f_scalar_stack_1(i32 signext %0, i128 %1, double %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { entry: %sisiext = sext i8 %6 to i32 %uisiext = zext i8 %7 to i32 @@ -31,7 +31,7 @@ entry: ret i32 %add } -define void @test_f_scalar_stack_2(ptr noalias sret(%Large) align 8 %0, double %1, i128 %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { +define void @test.f_scalar_stack_2(ptr noalias sret(%Large) align 8 %0, double %1, i128 %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { entry: %literal = alloca %Large, align 8 %8 = getelementptr inbounds %Large, ptr %literal, i32 0, i32 0 diff --git a/test/test_suite/abi/riscv64-lp64-lp64f-abi-2.c3t b/test/test_suite/abi/riscv64-lp64-lp64f-abi-2.c3t index 753ecdefa..f4d055a7d 100644 --- a/test/test_suite/abi/riscv64-lp64-lp64f-abi-2.c3t +++ b/test/test_suite/abi/riscv64-lp64-lp64f-abi-2.c3t @@ -24,7 +24,7 @@ fn Large f_scalar_stack_2(double a, int128 b, float128 c, char[<32>] d, /* #expect: test.ll -define signext i32 @test_f_scalar_stack_1(i32 signext %0, i128 %1, double %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { +define signext i32 @test.f_scalar_stack_1(i32 signext %0, i128 %1, double %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { entry: %sisiext = sext i8 %6 to i32 %uisiext = zext i8 %7 to i32 @@ -32,7 +32,7 @@ entry: ret i32 %add } -define void @test_f_scalar_stack_2(ptr noalias sret(%Large) align 8 %0, double %1, i128 %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { +define void @test.f_scalar_stack_2(ptr noalias sret(%Large) align 8 %0, double %1, i128 %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { entry: %literal = alloca %Large, align 8 %8 = getelementptr inbounds %Large, ptr %literal, i32 0, i32 0 diff --git a/test/test_suite/abi/riscv64-lp64-lp64f-lp64d-abi-1.c3t b/test/test_suite/abi/riscv64-lp64-lp64f-lp64d-abi-1.c3t index 4c63b6fb6..af916aa60 100644 --- a/test/test_suite/abi/riscv64-lp64-lp64f-lp64d-abi-1.c3t +++ b/test/test_suite/abi/riscv64-lp64-lp64f-lp64d-abi-1.c3t @@ -143,7 +143,6 @@ fn Large f_scalar_stack_3(uint a, int128 b, float128 c, char[<32>] d, fn int f_va_callee(int, ...); -// CHECK-LABEL: define{{.*}} void @f_va_caller() fn void f_va_caller() { float128 fq; f_va_callee(1, 2, 3i64, 4.0f, 5.0, Tiny{6, 7, 8, 9}, @@ -163,46 +162,46 @@ fn void f_va_caller() { /* #expect: test.ll -define void @test_f_void() -define zeroext i8 @test_f_scalar_0(i8 zeroext %0) -define signext i32 @test_f_scalar_1(i8 signext %0) -define zeroext i8 @test_f_scalar_2(i8 zeroext %0) -define signext i32 @test_f_scalar_3(i32 signext %0) -define i64 @test_f_scalar_4(i64 %0) -define float @test_f_fp_scalar_1(float %0) -define double @test_f_fp_scalar_2(double %0) -define fp128 @test_f_fp_scalar_3(fp128 %0) -define void @test_f_agg_tiny(i64 %0) -define i64 @test_f_agg_tiny_ret() -define void @test_f_vec_tiny_v4i16(i64 %0) -define i64 @test_f_vec_tiny_v4i16_ret() -define void @test_f_vec_tiny_v1i64(i64 %0) -define i64 @test_f_vec_tiny_v1i64_ret() -define void @test_f_agg_small([2 x i64] -define [2 x i64] @test_f_agg_small_ret() -define void @test_f_vec_small_v8i16(i128 %0) -define i128 @test_f_vec_small_v8i16_ret() -define void @test_f_vec_small_v1i128(i128 %0) -define i128 @test_f_vec_small_v1i128_ret() -define void @test_f_agg_small_aligned(i128 %0) -define i128 @test_f_agg_small_aligned_ret(i128 %0) -define void @test_f_agg_large(ptr align 8 %0) -define void @test_f_agg_large_ret(ptr noalias sret(%Large) align 8 %0, i32 signext %1, i8 signext %2) -define void @test_f_vec_large_v32i8(ptr align 32 %0) -define void @test_f_vec_large_v32i8_ret(ptr noalias sret(<32 x i8>) align 32 %0) -define signext i32 @test_f_scalar_stack_1(i64 %0, [2 x i64] %1, i128 %2, ptr align 8 %3, i8 zeroext %4, i8 signext %5, i8 %6, i8 %7) -define signext i32 @test_f_scalar_stack_2(i32 signext %0, i128 %1, i64 %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { -define void @test_f_scalar_stack_3(ptr noalias sret(%Large) align 8 %0, i32 signext %1, i128 %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) -declare signext i32 @test_f_va_callee(i32 signext, ...) #0 +define void @test.f_void() +define zeroext i8 @test.f_scalar_0(i8 zeroext %0) +define signext i32 @test.f_scalar_1(i8 signext %0) +define zeroext i8 @test.f_scalar_2(i8 zeroext %0) +define signext i32 @test.f_scalar_3(i32 signext %0) +define i64 @test.f_scalar_4(i64 %0) +define float @test.f_fp_scalar_1(float %0) +define double @test.f_fp_scalar_2(double %0) +define fp128 @test.f_fp_scalar_3(fp128 %0) +define void @test.f_agg_tiny(i64 %0) +define i64 @test.f_agg_tiny_ret() +define void @test.f_vec_tiny_v4i16(i64 %0) +define i64 @test.f_vec_tiny_v4i16_ret() +define void @test.f_vec_tiny_v1i64(i64 %0) +define i64 @test.f_vec_tiny_v1i64_ret() +define void @test.f_agg_small([2 x i64] +define [2 x i64] @test.f_agg_small_ret() +define void @test.f_vec_small_v8i16(i128 %0) +define i128 @test.f_vec_small_v8i16_ret() +define void @test.f_vec_small_v1i128(i128 %0) +define i128 @test.f_vec_small_v1i128_ret() +define void @test.f_agg_small_aligned(i128 %0) +define i128 @test.f_agg_small_aligned_ret(i128 %0) +define void @test.f_agg_large(ptr align 8 %0) +define void @test.f_agg_large_ret(ptr noalias sret(%Large) align 8 %0, i32 signext %1, i8 signext %2) +define void @test.f_vec_large_v32i8(ptr align 32 %0) +define void @test.f_vec_large_v32i8_ret(ptr noalias sret(<32 x i8>) align 32 %0) +define signext i32 @test.f_scalar_stack_1(i64 %0, [2 x i64] %1, i128 %2, ptr align 8 %3, i8 zeroext %4, i8 signext %5, i8 %6, i8 %7) +define signext i32 @test.f_scalar_stack_2(i32 signext %0, i128 %1, i64 %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { +define void @test.f_scalar_stack_3(ptr noalias sret(%Large) align 8 %0, i32 signext %1, i128 %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) +declare signext i32 @test.f_va_callee(i32 signext, ...) #0 call void @llvm.memcpy.p0.p0.i32(ptr align 8 %indirectarg, ptr align 8 %literal3, i32 32, i1 false) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i64 3, double 4.000000e+00, double 5.000000e+00, i64 %4, [2 x i64] %7, i128 %9, ptr align 8 %indirectarg) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, fp128 %15, i32 signext 6, i32 signext 7, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i128 %18, i32 signext 6, i32 signext 7, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, [2 x i64] %22, i32 signext 6, i32 signext 7, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, fp128 %24, i32 7, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i128 %27, i32 7, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, [2 x i64] %31, i32 signext 7, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i32 signext 6, fp128 %33, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i32 signext 6, i128 %36, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i32 signext 6, [2 x i64] %40, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i64 3, double 4.000000e+00, double 5.000000e+00, i64 %4, [2 x i64] %7, i128 %9, ptr align 8 %indirectarg) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, fp128 %15, i32 signext 6, i32 signext 7, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i128 %18, i32 signext 6, i32 signext 7, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, [2 x i64] %22, i32 signext 6, i32 signext 7, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, fp128 %24, i32 7, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i128 %27, i32 7, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, [2 x i64] %31, i32 signext 7, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i32 signext 6, fp128 %33, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i32 signext 6, i128 %36, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i32 signext 6, [2 x i64] %40, i32 8, i32 9) d \ No newline at end of file diff --git a/test/test_suite/abi/riscv64-lp64-lp64f-lp64d-abi-2.c3t b/test/test_suite/abi/riscv64-lp64-lp64f-lp64d-abi-2.c3t index 53eb8134e..29763fd55 100644 --- a/test/test_suite/abi/riscv64-lp64-lp64f-lp64d-abi-2.c3t +++ b/test/test_suite/abi/riscv64-lp64-lp64f-lp64d-abi-2.c3t @@ -144,7 +144,6 @@ fn Large f_scalar_stack_3(uint a, int128 b, float128 c, char[<32>] d, fn int f_va_callee(int, ...); -// CHECK-LABEL: define{{.*}} void @f_va_caller() fn void f_va_caller() { float128 fq; f_va_callee(1, 2, 3i64, 4.0f, 5.0, Tiny{6, 7, 8, 9}, @@ -164,45 +163,45 @@ fn void f_va_caller() { /* #expect: test.ll -define void @test_f_void() -define zeroext i8 @test_f_scalar_0(i8 zeroext %0) -define signext i32 @test_f_scalar_1(i8 signext %0) -define zeroext i8 @test_f_scalar_2(i8 zeroext %0) -define signext i32 @test_f_scalar_3(i32 signext %0) -define i64 @test_f_scalar_4(i64 %0) -define float @test_f_fp_scalar_1(float %0) -define double @test_f_fp_scalar_2(double %0) -define fp128 @test_f_fp_scalar_3(fp128 %0) -define void @test_f_agg_tiny(i64 %0) -define i64 @test_f_agg_tiny_ret() -define void @test_f_vec_tiny_v4i16(i64 %0) -define i64 @test_f_vec_tiny_v4i16_ret() -define void @test_f_vec_tiny_v1i64(i64 %0) -define i64 @test_f_vec_tiny_v1i64_ret() -define void @test_f_agg_small([2 x i64] -define [2 x i64] @test_f_agg_small_ret() -define void @test_f_vec_small_v8i16(i128 %0) -define i128 @test_f_vec_small_v8i16_ret() -define void @test_f_vec_small_v1i128(i128 %0) -define i128 @test_f_vec_small_v1i128_ret() -define void @test_f_agg_small_aligned(i128 %0) -define i128 @test_f_agg_small_aligned_ret(i128 %0) -define void @test_f_agg_large(ptr align 8 %0) -define void @test_f_agg_large_ret(ptr noalias sret(%Large) align 8 %0, i32 signext %1, i8 signext %2) -define void @test_f_vec_large_v32i8(ptr align 32 %0) -define void @test_f_vec_large_v32i8_ret(ptr noalias sret(<32 x i8>) align 32 %0) -define signext i32 @test_f_scalar_stack_1(i64 %0, [2 x i64] %1, i128 %2, ptr align 8 %3, i8 zeroext %4, i8 signext %5, i8 %6, i8 %7) -define signext i32 @test_f_scalar_stack_2(i32 signext %0, i128 %1, i64 %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { -define void @test_f_scalar_stack_3(ptr noalias sret(%Large) align 8 %0, i32 signext %1, i128 %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) -declare signext i32 @test_f_va_callee(i32 signext, ...) #0 +define void @test.f_void() +define zeroext i8 @test.f_scalar_0(i8 zeroext %0) +define signext i32 @test.f_scalar_1(i8 signext %0) +define zeroext i8 @test.f_scalar_2(i8 zeroext %0) +define signext i32 @test.f_scalar_3(i32 signext %0) +define i64 @test.f_scalar_4(i64 %0) +define float @test.f_fp_scalar_1(float %0) +define double @test.f_fp_scalar_2(double %0) +define fp128 @test.f_fp_scalar_3(fp128 %0) +define void @test.f_agg_tiny(i64 %0) +define i64 @test.f_agg_tiny_ret() +define void @test.f_vec_tiny_v4i16(i64 %0) +define i64 @test.f_vec_tiny_v4i16_ret() +define void @test.f_vec_tiny_v1i64(i64 %0) +define i64 @test.f_vec_tiny_v1i64_ret() +define void @test.f_agg_small([2 x i64] +define [2 x i64] @test.f_agg_small_ret() +define void @test.f_vec_small_v8i16(i128 %0) +define i128 @test.f_vec_small_v8i16_ret() +define void @test.f_vec_small_v1i128(i128 %0) +define i128 @test.f_vec_small_v1i128_ret() +define void @test.f_agg_small_aligned(i128 %0) +define i128 @test.f_agg_small_aligned_ret(i128 %0) +define void @test.f_agg_large(ptr align 8 %0) +define void @test.f_agg_large_ret(ptr noalias sret(%Large) align 8 %0, i32 signext %1, i8 signext %2) +define void @test.f_vec_large_v32i8(ptr align 32 %0) +define void @test.f_vec_large_v32i8_ret(ptr noalias sret(<32 x i8>) align 32 %0) +define signext i32 @test.f_scalar_stack_1(i64 %0, [2 x i64] %1, i128 %2, ptr align 8 %3, i8 zeroext %4, i8 signext %5, i8 %6, i8 %7) +define signext i32 @test.f_scalar_stack_2(i32 signext %0, i128 %1, i64 %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { +define void @test.f_scalar_stack_3(ptr noalias sret(%Large) align 8 %0, i32 signext %1, i128 %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) +declare signext i32 @test.f_va_callee(i32 signext, ...) #0 call void @llvm.memcpy.p0.p0.i32(ptr align 8 %indirectarg, ptr align 8 %literal3, i32 32, i1 false) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i64 3, double 4.000000e+00, double 5.000000e+00, i64 %4, [2 x i64] %7, i128 %9, ptr align 8 %indirectarg) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, fp128 %15, i32 signext 6, i32 signext 7, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i128 %18, i32 signext 6, i32 signext 7, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, [2 x i64] %22, i32 signext 6, i32 signext 7, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, fp128 %24, i32 7, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i128 %27, i32 7, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, [2 x i64] %31, i32 signext 7, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i32 signext 6, fp128 %33, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i32 signext 6, i128 %36, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i32 signext 6, [2 x i64] %40, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i64 3, double 4.000000e+00, double 5.000000e+00, i64 %4, [2 x i64] %7, i128 %9, ptr align 8 %indirectarg) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, fp128 %15, i32 signext 6, i32 signext 7, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i128 %18, i32 signext 6, i32 signext 7, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, [2 x i64] %22, i32 signext 6, i32 signext 7, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, fp128 %24, i32 7, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i128 %27, i32 7, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, [2 x i64] %31, i32 signext 7, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i32 signext 6, fp128 %33, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i32 signext 6, i128 %36, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i32 signext 6, [2 x i64] %40, i32 8, i32 9) diff --git a/test/test_suite/abi/riscv64-lp64-lp64f-lp64d-abi-3.c3t b/test/test_suite/abi/riscv64-lp64-lp64f-lp64d-abi-3.c3t index eea2a9ed9..9a83ccd76 100644 --- a/test/test_suite/abi/riscv64-lp64-lp64f-lp64d-abi-3.c3t +++ b/test/test_suite/abi/riscv64-lp64-lp64f-lp64d-abi-3.c3t @@ -144,7 +144,6 @@ fn Large f_scalar_stack_3(uint a, int128 b, float128 c, char[<32>] d, fn int f_va_callee(int, ...); -// CHECK-LABEL: define{{.*}} void @f_va_caller() fn void f_va_caller() { float128 fq; f_va_callee(1, 2, 3i64, 4.0f, 5.0, Tiny{6, 7, 8, 9}, @@ -164,45 +163,45 @@ fn void f_va_caller() { /* #expect: test.ll -define void @test_f_void() -define zeroext i8 @test_f_scalar_0(i8 zeroext %0) -define signext i32 @test_f_scalar_1(i8 signext %0) -define zeroext i8 @test_f_scalar_2(i8 zeroext %0) -define signext i32 @test_f_scalar_3(i32 signext %0) -define i64 @test_f_scalar_4(i64 %0) -define float @test_f_fp_scalar_1(float %0) -define double @test_f_fp_scalar_2(double %0) -define fp128 @test_f_fp_scalar_3(fp128 %0) -define void @test_f_agg_tiny(i64 %0) -define i64 @test_f_agg_tiny_ret() -define void @test_f_vec_tiny_v4i16(i64 %0) -define i64 @test_f_vec_tiny_v4i16_ret() -define void @test_f_vec_tiny_v1i64(i64 %0) -define i64 @test_f_vec_tiny_v1i64_ret() -define void @test_f_agg_small([2 x i64] -define [2 x i64] @test_f_agg_small_ret() -define void @test_f_vec_small_v8i16(i128 %0) -define i128 @test_f_vec_small_v8i16_ret() -define void @test_f_vec_small_v1i128(i128 %0) -define i128 @test_f_vec_small_v1i128_ret() -define void @test_f_agg_small_aligned(i128 %0) -define i128 @test_f_agg_small_aligned_ret(i128 %0) -define void @test_f_agg_large(ptr align 8 %0) -define void @test_f_agg_large_ret(ptr noalias sret(%Large) align 8 %0, i32 signext %1, i8 signext %2) -define void @test_f_vec_large_v32i8(ptr align 32 %0) -define void @test_f_vec_large_v32i8_ret(ptr noalias sret(<32 x i8>) align 32 %0) -define signext i32 @test_f_scalar_stack_1(i64 %0, [2 x i64] %1, i128 %2, ptr align 8 %3, i8 zeroext %4, i8 signext %5, i8 %6, i8 %7) -define signext i32 @test_f_scalar_stack_2(i32 signext %0, i128 %1, i64 %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { -define void @test_f_scalar_stack_3(ptr noalias sret(%Large) align 8 %0, i32 signext %1, i128 %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) -declare signext i32 @test_f_va_callee(i32 signext, ...) #0 +define void @test.f_void() +define zeroext i8 @test.f_scalar_0(i8 zeroext %0) +define signext i32 @test.f_scalar_1(i8 signext %0) +define zeroext i8 @test.f_scalar_2(i8 zeroext %0) +define signext i32 @test.f_scalar_3(i32 signext %0) +define i64 @test.f_scalar_4(i64 %0) +define float @test.f_fp_scalar_1(float %0) +define double @test.f_fp_scalar_2(double %0) +define fp128 @test.f_fp_scalar_3(fp128 %0) +define void @test.f_agg_tiny(i64 %0) +define i64 @test.f_agg_tiny_ret() +define void @test.f_vec_tiny_v4i16(i64 %0) +define i64 @test.f_vec_tiny_v4i16_ret() +define void @test.f_vec_tiny_v1i64(i64 %0) +define i64 @test.f_vec_tiny_v1i64_ret() +define void @test.f_agg_small([2 x i64] +define [2 x i64] @test.f_agg_small_ret() +define void @test.f_vec_small_v8i16(i128 %0) +define i128 @test.f_vec_small_v8i16_ret() +define void @test.f_vec_small_v1i128(i128 %0) +define i128 @test.f_vec_small_v1i128_ret() +define void @test.f_agg_small_aligned(i128 %0) +define i128 @test.f_agg_small_aligned_ret(i128 %0) +define void @test.f_agg_large(ptr align 8 %0) +define void @test.f_agg_large_ret(ptr noalias sret(%Large) align 8 %0, i32 signext %1, i8 signext %2) +define void @test.f_vec_large_v32i8(ptr align 32 %0) +define void @test.f_vec_large_v32i8_ret(ptr noalias sret(<32 x i8>) align 32 %0) +define signext i32 @test.f_scalar_stack_1(i64 %0, [2 x i64] %1, i128 %2, ptr align 8 %3, i8 zeroext %4, i8 signext %5, i8 %6, i8 %7) +define signext i32 @test.f_scalar_stack_2(i32 signext %0, i128 %1, i64 %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) #0 { +define void @test.f_scalar_stack_3(ptr noalias sret(%Large) align 8 %0, i32 signext %1, i128 %2, fp128 %3, ptr align 32 %4, i8 zeroext %5, i8 %6, i8 %7) +declare signext i32 @test.f_va_callee(i32 signext, ...) #0 call void @llvm.memcpy.p0.p0.i32(ptr align 8 %indirectarg, ptr align 8 %literal3, i32 32, i1 false) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i64 3, double 4.000000e+00, double 5.000000e+00, i64 %4, [2 x i64] %7, i128 %9, ptr align 8 %indirectarg) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, fp128 %15, i32 signext 6, i32 signext 7, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i128 %18, i32 signext 6, i32 signext 7, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, [2 x i64] %22, i32 signext 6, i32 signext 7, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, fp128 %24, i32 7, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i128 %27, i32 7, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, [2 x i64] %31, i32 signext 7, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i32 signext 6, fp128 %33, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i32 signext 6, i128 %36, i32 8, i32 9) -call i32 (i32, ...) @test_f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i32 signext 6, [2 x i64] %40, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i64 3, double 4.000000e+00, double 5.000000e+00, i64 %4, [2 x i64] %7, i128 %9, ptr align 8 %indirectarg) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, fp128 %15, i32 signext 6, i32 signext 7, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i128 %18, i32 signext 6, i32 signext 7, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, [2 x i64] %22, i32 signext 6, i32 signext 7, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, fp128 %24, i32 7, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i128 %27, i32 7, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, [2 x i64] %31, i32 signext 7, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i32 signext 6, fp128 %33, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i32 signext 6, i128 %36, i32 8, i32 9) +call i32 (i32, ...) @test.f_va_callee(i32 signext 1, i32 signext 2, i32 signext 3, i32 signext 4, i32 signext 5, i32 signext 6, [2 x i64] %40, i32 8, i32 9) diff --git a/test/test_suite/abi/riscv64-lp64d-abi.c3t b/test/test_suite/abi/riscv64-lp64d-abi.c3t index b61b64508..88e7c9ab1 100644 --- a/test/test_suite/abi/riscv64-lp64d-abi.c3t +++ b/test/test_suite/abi/riscv64-lp64d-abi.c3t @@ -153,13 +153,13 @@ fn Double_u f_ret_double_u() { /* #expect: test.ll -define void @test_f_fpr_tracking(double %0, double %1, double %2, double %3, double %4, double %5, double %6, double %7, i8 zeroext %8) #0 { +define void @test.f_fpr_tracking(double %0, double %1, double %2, double %3, double %4, double %5, double %6, double %7, i8 zeroext %8) #0 { entry: ret void } -define void @test_f_double_s_arg(double %0) #0 { +define void @test.f_double_s_arg(double %0) #0 { entry: %a = alloca %Double_s, align 8 store double %0, ptr %a, align 8 @@ -167,7 +167,7 @@ entry: } -define double @test_f_ret_double_s() #0 { +define double @test.f_ret_double_s() #0 { entry: %literal = alloca %Double_s, align 8 %0 = getelementptr inbounds %Double_s, ptr %literal, i32 0, i32 0 @@ -177,7 +177,7 @@ entry: } -define void @test_f_double_double_s_arg(double %0, double %1) #0 { +define void @test.f_double_double_s_arg(double %0, double %1) #0 { entry: %a = alloca %Double_double_s, align 8 store double %0, ptr %a, align 8 @@ -187,7 +187,7 @@ entry: } -define { double, double } @test_f_ret_double_double_s() #0 { +define { double, double } @test.f_ret_double_double_s() #0 { entry: %literal = alloca %Double_double_s, align 8 %0 = getelementptr inbounds %Double_double_s, ptr %literal, i32 0, i32 0 @@ -203,7 +203,7 @@ entry: } -define void @test_f_double_float_s_arg(double %0, float %1) #0 { +define void @test.f_double_float_s_arg(double %0, float %1) #0 { entry: %a = alloca %Double_float_s, align 8 store double %0, ptr %a, align 8 @@ -213,7 +213,7 @@ entry: } -define { double, float } @test_f_ret_double_float_s() #0 { +define { double, float } @test.f_ret_double_float_s() #0 { entry: %literal = alloca %Double_float_s, align 8 %0 = getelementptr inbounds %Double_float_s, ptr %literal, i32 0, i32 0 @@ -229,7 +229,7 @@ entry: } -define void @test_f_double_double_s_arg_insufficient_fprs(float %0, double %1, double %2, double %3, double %4, double %5, double %6, [2 x i64] %7) #0 { +define void @test.f_double_double_s_arg_insufficient_fprs(float %0, double %1, double %2, double %3, double %4, double %5, double %6, [2 x i64] %7) #0 { entry: %h = alloca %Double_double_s, align 8 store [2 x i64] %7, ptr %h, align 8 @@ -237,7 +237,7 @@ entry: } -define void @test_f_double_int8_s_arg(double %0, i8 %1) #0 { +define void @test.f_double_int8_s_arg(double %0, i8 %1) #0 { entry: %a = alloca %Double_int8_s, align 8 store double %0, ptr %a, align 8 @@ -247,7 +247,7 @@ entry: } -define { double, i8 } @test_f_ret_double_int8_s() #0 { +define { double, i8 } @test.f_ret_double_int8_s() #0 { entry: %literal = alloca %Double_int8_s, align 8 %0 = getelementptr inbounds %Double_int8_s, ptr %literal, i32 0, i32 0 @@ -263,7 +263,7 @@ entry: } -define void @test_f_double_uint8_s_arg(double %0, i8 %1) #0 { +define void @test.f_double_uint8_s_arg(double %0, i8 %1) #0 { entry: %a = alloca %Double_uint8_s, align 8 store double %0, ptr %a, align 8 @@ -273,7 +273,7 @@ entry: } -define { double, i8 } @test_f_ret_double_uint8_s() #0 { +define { double, i8 } @test.f_ret_double_uint8_s() #0 { entry: %literal = alloca %Double_uint8_s, align 8 %0 = getelementptr inbounds %Double_uint8_s, ptr %literal, i32 0, i32 0 @@ -289,7 +289,7 @@ entry: } -define void @test_f_double_int32_s_arg(double %0, i32 %1) #0 { +define void @test.f_double_int32_s_arg(double %0, i32 %1) #0 { entry: %a = alloca %Double_int32_s, align 8 store double %0, ptr %a, align 8 @@ -299,7 +299,7 @@ entry: } -define { double, i32 } @test_f_ret_double_int32_s() #0 { +define { double, i32 } @test.f_ret_double_int32_s() #0 { entry: %literal = alloca %Double_int32_s, align 8 %0 = getelementptr inbounds %Double_int32_s, ptr %literal, i32 0, i32 0 @@ -315,7 +315,7 @@ entry: } -define void @test_f_double_int64_s_arg(double %0, i64 %1) #0 { +define void @test.f_double_int64_s_arg(double %0, i64 %1) #0 { entry: %a = alloca %Double_int64_s, align 8 store double %0, ptr %a, align 8 @@ -325,7 +325,7 @@ entry: } -define { double, i64 } @test_f_ret_double_int64_s() #0 { +define { double, i64 } @test.f_ret_double_int64_s() #0 { entry: %literal = alloca %Double_int64_s, align 8 %0 = getelementptr inbounds %Double_int64_s, ptr %literal, i32 0, i32 0 @@ -341,7 +341,7 @@ entry: } -define void @test_f_double_int8_s_arg_insufficient_gprs(i32 signext %0, i32 signext %1, i32 signext %2, i32 signext %3, i32 signext %4, i32 signext %5, i32 signext %6, i32 signext %7, [2 x i64] %8) #0 { +define void @test.f_double_int8_s_arg_insufficient_gprs(i32 signext %0, i32 signext %1, i32 signext %2, i32 signext %3, i32 signext %4, i32 signext %5, i32 signext %6, i32 signext %7, [2 x i64] %8) #0 { entry: %i = alloca %Double_int8_s, align 8 store [2 x i64] %8, ptr %i, align 8 @@ -349,7 +349,7 @@ entry: } -define void @test_f_struct_double_int8_insufficient_fprs(float %0, double %1, double %2, double %3, double %4, double %5, double %6, double %7, [2 x i64] %8) #0 { +define void @test.f_struct_double_int8_insufficient_fprs(float %0, double %1, double %2, double %3, double %4, double %5, double %6, double %7, [2 x i64] %8) #0 { entry: %i = alloca %Double_int8_s, align 8 store [2 x i64] %8, ptr %i, align 8 @@ -357,7 +357,7 @@ entry: } -define void @test_f_doublearr1_s_arg(double %0) #0 { +define void @test.f_doublearr1_s_arg(double %0) #0 { entry: %a = alloca %Doublearr1_s, align 8 store double %0, ptr %a, align 8 @@ -365,7 +365,7 @@ entry: } -define double @test_f_ret_doublearr1_s() #0 { +define double @test.f_ret_doublearr1_s() #0 { entry: %literal = alloca %Doublearr1_s, align 8 %0 = getelementptr inbounds %Doublearr1_s, ptr %literal, i32 0, i32 0 @@ -376,7 +376,7 @@ entry: } -define void @test_f_doublearr2_s_arg(double %0, double %1) #0 { +define void @test.f_doublearr2_s_arg(double %0, double %1) #0 { entry: %a = alloca %Doublearr2_s, align 8 store double %0, ptr %a, align 8 @@ -386,7 +386,7 @@ entry: } -define { double, double } @test_f_ret_doublearr2_s() #0 { +define { double, double } @test.f_ret_doublearr2_s() #0 { entry: %literal = alloca %Doublearr2_s, align 8 %0 = getelementptr inbounds %Doublearr2_s, ptr %literal, i32 0, i32 0 @@ -403,7 +403,7 @@ entry: } -define void @test_f_doublearr2_tricky1_s_arg(double %0, double %1) #0 { +define void @test.f_doublearr2_tricky1_s_arg(double %0, double %1) #0 { entry: %a = alloca %Doublearr2_tricky1_s, align 8 store double %0, ptr %a, align 8 @@ -413,7 +413,7 @@ entry: } -define { double, double } @test_f_ret_doublearr2_tricky1_s() #0 { +define { double, double } @test.f_ret_doublearr2_tricky1_s() #0 { entry: %literal = alloca %Doublearr2_tricky1_s, align 8 %0 = getelementptr inbounds %Doublearr2_tricky1_s, ptr %literal, i32 0, i32 0 @@ -434,13 +434,13 @@ entry: } -define void @test_f_int_double_int_s_arg(ptr align 8 %0) #0 { +define void @test.f_int_double_int_s_arg(ptr align 8 %0) #0 { entry: ret void } -define void @test_f_ret_int_double_int_s(ptr noalias sret(%Int_double_int_s) align 8 %0) #0 { +define void @test.f_ret_int_double_int_s(ptr noalias sret(%Int_double_int_s) align 8 %0) #0 { entry: %literal = alloca %Int_double_int_s, align 8 %1 = getelementptr inbounds %Int_double_int_s, ptr %literal, i32 0, i32 0 @@ -454,7 +454,7 @@ entry: } -define void @test_f_char_char_double_s_arg([2 x i64] %0) #0 { +define void @test.f_char_char_double_s_arg([2 x i64] %0) #0 { entry: %a = alloca %Char_char_double_s, align 8 store [2 x i64] %0, ptr %a, align 8 @@ -462,7 +462,7 @@ entry: } -define [2 x i64] @test_f_ret_char_char_double_s() #0 { +define [2 x i64] @test.f_ret_char_char_double_s() #0 { entry: %literal = alloca %Char_char_double_s, align 8 %0 = getelementptr inbounds %Char_char_double_s, ptr %literal, i32 0, i32 0 @@ -476,7 +476,7 @@ entry: } -define void @test_f_double_u_arg(i64 %0) #0 { +define void @test.f_double_u_arg(i64 %0) #0 { entry: %a = alloca %Double_u, align 8 store i64 %0, ptr %a, align 8 @@ -484,7 +484,7 @@ entry: } -define i64 @test_f_ret_double_u() #0 { +define i64 @test.f_ret_double_u() #0 { entry: %literal = alloca %Double_u, align 8 store double 1.000000e+00, ptr %literal, align 8 diff --git a/test/test_suite/abi/riscv64-lp64f-lp64d-abi-1.c3t b/test/test_suite/abi/riscv64-lp64f-lp64d-abi-1.c3t index bf0c793fe..2ffa8a903 100644 --- a/test/test_suite/abi/riscv64-lp64f-lp64d-abi-1.c3t +++ b/test/test_suite/abi/riscv64-lp64f-lp64d-abi-1.c3t @@ -135,50 +135,50 @@ fn Float_u f_ret_float_u() { /* #expect: test.ll -define void @test_f_fpr_tracking(float %0, float %1, float %2, float %3, float %4, float %5, float %6, float %7, i8 zeroext %8) #0 { +define void @test.f_fpr_tracking(float %0, float %1, float %2, float %3, float %4, float %5, float %6, float %7, i8 zeroext %8) #0 { -define void @test_f_float_s_arg(float %0) #0 { -define float @test_f_ret_float_s() #0 { +define void @test.f_float_s_arg(float %0) #0 { +define float @test.f_ret_float_s() #0 { -define void @test_f_float_float_s_arg(float %0, float %1) #0 { -define { float, float } @test_f_ret_float_float_s() #0 { -define void @test_f_float_float_s_arg_insufficient_fprs(float %0, float %1, float %2, float %3, float %4, float %5, float %6, i64 %7) #0 { -define void @test_f_float_int8_s_arg(float %0, i8 %1) #0 { -define { float, i8 } @test_f_ret_float_int8_s() #0 { +define void @test.f_float_float_s_arg(float %0, float %1) #0 { +define { float, float } @test.f_ret_float_float_s() #0 { +define void @test.f_float_float_s_arg_insufficient_fprs(float %0, float %1, float %2, float %3, float %4, float %5, float %6, i64 %7) #0 { +define void @test.f_float_int8_s_arg(float %0, i8 %1) #0 { +define { float, i8 } @test.f_ret_float_int8_s() #0 { -define void @test_f_float_uint8_s_arg(float %0, i8 %1) #0 { +define void @test.f_float_uint8_s_arg(float %0, i8 %1) #0 { -define { float, i8 } @test_f_ret_float_uint8_s() #0 { +define { float, i8 } @test.f_ret_float_uint8_s() #0 { -define void @test_f_float_int32_s_arg(float %0, i32 %1) #0 { +define void @test.f_float_int32_s_arg(float %0, i32 %1) #0 { -define { float, i32 } @test_f_ret_float_int32_s() #0 { -define void @test_f_float_int64_s_arg(float %0, i64 %1) #0 { +define { float, i32 } @test.f_ret_float_int32_s() #0 { +define void @test.f_float_int64_s_arg(float %0, i64 %1) #0 { -define { float, i64 } @test_f_ret_float_int64_s() #0 { +define { float, i64 } @test.f_ret_float_int64_s() #0 { -define void @test_f_float_int8_s_arg_insufficient_gprs(i32 signext %0, i32 signext %1, i32 signext %2, i32 signext %3, i32 signext %4, i32 signext %5, i32 signext %6, i32 signext %7, i64 %8) #0 { +define void @test.f_float_int8_s_arg_insufficient_gprs(i32 signext %0, i32 signext %1, i32 signext %2, i32 signext %3, i32 signext %4, i32 signext %5, i32 signext %6, i32 signext %7, i64 %8) #0 { -define void @test_f_struct_float_int8_insufficient_fprs(float %0, float %1, float %2, float %3, float %4, float %5, float %6, float %7, i64 %8) #0 { +define void @test.f_struct_float_int8_insufficient_fprs(float %0, float %1, float %2, float %3, float %4, float %5, float %6, float %7, i64 %8) #0 { -define void @test_f_floatarr1_s_arg(float %0) #0 { +define void @test.f_floatarr1_s_arg(float %0) #0 { -define float @test_f_ret_floatarr1_s() #0 { +define float @test.f_ret_floatarr1_s() #0 { -define void @test_f_floatarr2_s_arg(float %0, float %1) #0 { +define void @test.f_floatarr2_s_arg(float %0, float %1) #0 { -define { float, float } @test_f_ret_floatarr2_s() #0 { +define { float, float } @test.f_ret_floatarr2_s() #0 { -define void @test_f_floatarr2_tricky1_s_arg(float %0, float %1) #0 { +define void @test.f_floatarr2_tricky1_s_arg(float %0, float %1) #0 { -define { float, float } @test_f_ret_floatarr2_tricky1_s() #0 { +define { float, float } @test.f_ret_floatarr2_tricky1_s() #0 { -define void @test_f_int_float_int_s_arg([2 x i64] %0) #0 { +define void @test.f_int_float_int_s_arg([2 x i64] %0) #0 { -define [2 x i64] @test_f_ret_int_float_int_s() #0 { +define [2 x i64] @test.f_ret_int_float_int_s() #0 { -define void @test_f_char_char_float_s_arg(i64 %0) #0 { -define i64 @test_f_ret_char_char_float_s() #0 { +define void @test.f_char_char_float_s_arg(i64 %0) #0 { +define i64 @test.f_ret_char_char_float_s() #0 { -define void @test_f_float_u_arg(i64 %0) #0 { -define i64 @test_f_ret_float_u() #0 { +define void @test.f_float_u_arg(i64 %0) #0 { +define i64 @test.f_ret_float_u() #0 { diff --git a/test/test_suite/abi/riscv64-lp64f-lp64d-abi-2.c3t b/test/test_suite/abi/riscv64-lp64f-lp64d-abi-2.c3t index c32a0e727..c29027117 100644 --- a/test/test_suite/abi/riscv64-lp64f-lp64d-abi-2.c3t +++ b/test/test_suite/abi/riscv64-lp64f-lp64d-abi-2.c3t @@ -135,16 +135,16 @@ fn Float_u f_ret_float_u() { /* #expect: test.ll -define void @test_f_fpr_tracking(float %0, float %1, float %2, float %3, float %4, float %5, float %6, float %7, i8 zeroext %8) #0 { +define void @test.f_fpr_tracking(float %0, float %1, float %2, float %3, float %4, float %5, float %6, float %7, i8 zeroext %8) #0 { -define void @test_f_float_s_arg(float %0) #0 { +define void @test.f_float_s_arg(float %0) #0 { entry: %a = alloca %Float_s, align 4 store float %0, ptr %a, align 4 ret void } -define float @test_f_ret_float_s() #0 { +define float @test.f_ret_float_s() #0 { entry: %literal = alloca %Float_s, align 4 %0 = getelementptr inbounds %Float_s, ptr %literal, i32 0, i32 0 @@ -153,7 +153,7 @@ entry: ret float %1 } -define void @test_f_float_float_s_arg(float %0, float %1) #0 { +define void @test.f_float_float_s_arg(float %0, float %1) #0 { entry: %a = alloca %Float_float_s, align 4 store float %0, ptr %a, align 4 @@ -162,7 +162,7 @@ entry: ret void } -define { float, float } @test_f_ret_float_float_s() #0 { +define { float, float } @test.f_ret_float_float_s() #0 { entry: %literal = alloca %Float_float_s, align 4 %0 = getelementptr inbounds %Float_float_s, ptr %literal, i32 0, i32 0 @@ -177,14 +177,14 @@ entry: ret { float, float } %5 } -define void @test_f_float_float_s_arg_insufficient_fprs(float %0, float %1, float %2, float %3, float %4, float %5, float %6, i64 %7) #0 { +define void @test.f_float_float_s_arg_insufficient_fprs(float %0, float %1, float %2, float %3, float %4, float %5, float %6, i64 %7) #0 { entry: %h = alloca %Float_float_s, align 4 store i64 %7, ptr %h, align 4 ret void } -define void @test_f_float_int8_s_arg(float %0, i8 %1) #0 { +define void @test.f_float_int8_s_arg(float %0, i8 %1) #0 { entry: %a = alloca %Float_int8_s, align 4 store float %0, ptr %a, align 4 @@ -193,7 +193,7 @@ entry: ret void } -define { float, i8 } @test_f_ret_float_int8_s() #0 { +define { float, i8 } @test.f_ret_float_int8_s() #0 { entry: %literal = alloca %Float_int8_s, align 4 %0 = getelementptr inbounds %Float_int8_s, ptr %literal, i32 0, i32 0 @@ -208,7 +208,7 @@ entry: ret { float, i8 } %5 } -define void @test_f_float_uint8_s_arg(float %0, i8 %1) #0 { +define void @test.f_float_uint8_s_arg(float %0, i8 %1) #0 { entry: %a = alloca %Float_uint8_s, align 4 store float %0, ptr %a, align 4 @@ -217,7 +217,7 @@ entry: ret void } -define { float, i8 } @test_f_ret_float_uint8_s() #0 { +define { float, i8 } @test.f_ret_float_uint8_s() #0 { entry: %literal = alloca %Float_uint8_s, align 4 %0 = getelementptr inbounds %Float_uint8_s, ptr %literal, i32 0, i32 0 @@ -232,7 +232,7 @@ entry: ret { float, i8 } %5 } -define void @test_f_float_int32_s_arg(float %0, i32 %1) #0 { +define void @test.f_float_int32_s_arg(float %0, i32 %1) #0 { entry: %a = alloca %Float_int32_s, align 4 store float %0, ptr %a, align 4 @@ -241,7 +241,7 @@ entry: ret void } -define { float, i32 } @test_f_ret_float_int32_s() #0 { +define { float, i32 } @test.f_ret_float_int32_s() #0 { entry: %literal = alloca %Float_int32_s, align 4 %0 = getelementptr inbounds %Float_int32_s, ptr %literal, i32 0, i32 0 @@ -256,7 +256,7 @@ entry: ret { float, i32 } %5 } -define void @test_f_float_int64_s_arg(float %0, i64 %1) #0 { +define void @test.f_float_int64_s_arg(float %0, i64 %1) #0 { entry: %a = alloca %Float_int64_s, align 8 store float %0, ptr %a, align 8 @@ -265,7 +265,7 @@ entry: ret void } -define { float, i64 } @test_f_ret_float_int64_s() #0 { +define { float, i64 } @test.f_ret_float_int64_s() #0 { entry: %literal = alloca %Float_int64_s, align 8 %0 = getelementptr inbounds %Float_int64_s, ptr %literal, i32 0, i32 0 @@ -280,28 +280,28 @@ entry: ret { float, i64 } %5 } -define void @test_f_float_int8_s_arg_insufficient_gprs(i32 signext %0, i32 signext %1, i32 signext %2, i32 signext %3, i32 signext %4, i32 signext %5, i32 signext %6, i32 signext %7, i64 %8) #0 { +define void @test.f_float_int8_s_arg_insufficient_gprs(i32 signext %0, i32 signext %1, i32 signext %2, i32 signext %3, i32 signext %4, i32 signext %5, i32 signext %6, i32 signext %7, i64 %8) #0 { entry: %i = alloca %Float_int8_s, align 4 store i64 %8, ptr %i, align 4 ret void } -define void @test_f_struct_float_int8_insufficient_fprs(float %0, float %1, float %2, float %3, float %4, float %5, float %6, float %7, i64 %8) #0 { +define void @test.f_struct_float_int8_insufficient_fprs(float %0, float %1, float %2, float %3, float %4, float %5, float %6, float %7, i64 %8) #0 { entry: %i = alloca %Float_int8_s, align 4 store i64 %8, ptr %i, align 4 ret void } -define void @test_f_floatarr1_s_arg(float %0) #0 { +define void @test.f_floatarr1_s_arg(float %0) #0 { entry: %a = alloca %Floatarr1_s, align 4 store float %0, ptr %a, align 4 ret void } -define float @test_f_ret_floatarr1_s() #0 { +define float @test.f_ret_floatarr1_s() #0 { entry: %literal = alloca %Floatarr1_s, align 4 %0 = getelementptr inbounds %Floatarr1_s, ptr %literal, i32 0, i32 0 @@ -311,7 +311,7 @@ entry: ret float %2 } -define void @test_f_floatarr2_s_arg(float %0, float %1) #0 { +define void @test.f_floatarr2_s_arg(float %0, float %1) #0 { entry: %a = alloca %Floatarr2_s, align 4 store float %0, ptr %a, align 4 @@ -320,7 +320,7 @@ entry: ret void } -define { float, float } @test_f_ret_floatarr2_s() #0 { +define { float, float } @test.f_ret_floatarr2_s() #0 { entry: %literal = alloca %Floatarr2_s, align 4 %0 = getelementptr inbounds %Floatarr2_s, ptr %literal, i32 0, i32 0 @@ -336,7 +336,7 @@ entry: ret { float, float } %6 } -define void @test_f_floatarr2_tricky1_s_arg(float %0, float %1) #0 { +define void @test.f_floatarr2_tricky1_s_arg(float %0, float %1) #0 { entry: %a = alloca %Floatarr2_tricky1_s, align 4 store float %0, ptr %a, align 4 @@ -345,7 +345,7 @@ entry: ret void } -define { float, float } @test_f_ret_floatarr2_tricky1_s() #0 { +define { float, float } @test.f_ret_floatarr2_tricky1_s() #0 { entry: %literal = alloca %Floatarr2_tricky1_s, align 4 %0 = getelementptr inbounds %Floatarr2_tricky1_s, ptr %literal, i32 0, i32 0 @@ -365,7 +365,7 @@ entry: ret { float, float } %10 } -define void @test_f_int_float_int_s_arg([2 x i64] %0) #0 { +define void @test.f_int_float_int_s_arg([2 x i64] %0) #0 { entry: %a = alloca %Int_float_int_s, align 4 %tempcoerce = alloca [2 x i64], align 8 @@ -374,7 +374,7 @@ entry: ret void } -define [2 x i64] @test_f_ret_int_float_int_s() #0 { +define [2 x i64] @test.f_ret_int_float_int_s() #0 { entry: %literal = alloca %Int_float_int_s, align 4 %tempcoerce = alloca [2 x i64], align 8 @@ -389,14 +389,14 @@ entry: ret [2 x i64] %3 } -define void @test_f_char_char_float_s_arg(i64 %0) #0 { +define void @test.f_char_char_float_s_arg(i64 %0) #0 { entry: %a = alloca %Char_char_float_s, align 4 store i64 %0, ptr %a, align 4 ret void } -define i64 @test_f_ret_char_char_float_s() #0 { +define i64 @test.f_ret_char_char_float_s() #0 { entry: %literal = alloca %Char_char_float_s, align 4 %0 = getelementptr inbounds %Char_char_float_s, ptr %literal, i32 0, i32 0 @@ -409,7 +409,7 @@ entry: ret i64 %3 } -define void @test_f_float_u_arg(i64 %0) #0 { +define void @test.f_float_u_arg(i64 %0) #0 { entry: %a = alloca %Float_u, align 4 %tempcoerce = alloca i64, align 8 @@ -418,7 +418,7 @@ entry: ret void } -define i64 @test_f_ret_float_u() #0 { +define i64 @test.f_ret_float_u() #0 { entry: %literal = alloca %Float_u, align 4 %tempcoerce = alloca i64, align 8 diff --git a/test/test_suite/abi/small_struct_x64.c3t b/test/test_suite/abi/small_struct_x64.c3t index bf7f52e1a..1c729bca4 100644 --- a/test/test_suite/abi/small_struct_x64.c3t +++ b/test/test_suite/abi/small_struct_x64.c3t @@ -23,10 +23,10 @@ fn Foo getFoo(Foo f) %.introspect = type { i8, i64, i64, i64, [0 x i64] } %Foo = type { i8, i8, i8 } -@"ct$test_Foo" = linkonce constant %.introspect { i8 10, i64 3, i64 0, i64 3, [0 x i64] zeroinitializer }, align 8 +@"ct$test.Foo" = linkonce constant %.introspect { i8 10, i64 3, i64 0, i64 3, [0 x i64] zeroinitializer }, align 8 ; Function Attrs: nounwind -define i32 @test_testing() #0 { +define i32 @test.testing() #0 { entry: %y = alloca %Foo, align 1 %literal = alloca %Foo, align 1 @@ -41,7 +41,7 @@ entry: store i8 6, ptr %2, align 1 call void @llvm.memcpy.p0.p0.i32(ptr align 4 %tempcoerce, ptr align 1 %literal, i32 3, i1 false) %3 = load i24, ptr %tempcoerce, align 4 - %4 = call i24 @test_getFoo(i24 %3) + %4 = call i24 @test.getFoo(i24 %3) store i24 %4, ptr %tempcoerce1, align 4 call void @llvm.memcpy.p0.p0.i32(ptr align 1 %result, ptr align 4 %tempcoerce1, i32 3, i1 false) call void @llvm.memcpy.p0.p0.i32(ptr align 1 %y, ptr align 1 %result, i32 3, i1 false) @@ -56,7 +56,7 @@ entry: } ; Function Attrs: nounwind -define i24 @test_getFoo(i24 %0) #0 { +define i24 @test.getFoo(i24 %0) #0 { entry: %f = alloca %Foo, align 1 %tempcoerce = alloca i24, align 4 diff --git a/test/test_suite/abi/sysv_abi_avx.c3t b/test/test_suite/abi/sysv_abi_avx.c3t index 44d71bb5c..59f42473d 100644 --- a/test/test_suite/abi/sysv_abi_avx.c3t +++ b/test/test_suite/abi/sysv_abi_avx.c3t @@ -34,7 +34,7 @@ fn void use_vectors() declare void @take_stringref(ptr, i64) #0 call void @take_stringref(ptr %lo, i64 %hi) -define void @foo_use_vectors() #0 { +define void @foo.use_vectors() #0 { entry: %0 = call <8 x float> @get_m256() call void @take_m256(<8 x float> %1) diff --git a/test/test_suite/abi/sysv_abi_noavx.c3t b/test/test_suite/abi/sysv_abi_noavx.c3t index e3ee93e90..a32ded346 100644 --- a/test/test_suite/abi/sysv_abi_noavx.c3t +++ b/test/test_suite/abi/sysv_abi_noavx.c3t @@ -34,7 +34,7 @@ fn void use_vectors() declare void @take_stringref(ptr, i64) #0 call void @take_stringref(ptr %lo, i64 %hi) -define void @foo_use_vectors() #0 { +define void @foo.use_vectors() #0 { %0 = call <8 x float> @get_m256() call void @take_m256(ptr byval(<8 x float>) align 32 %v1) %1 = call <16 x float> @get_m512() diff --git a/test/test_suite/abi/sysv_direct_coerce.c3t b/test/test_suite/abi/sysv_direct_coerce.c3t index add49d1fc..c57b3de15 100644 --- a/test/test_suite/abi/sysv_direct_coerce.c3t +++ b/test/test_suite/abi/sysv_direct_coerce.c3t @@ -16,7 +16,7 @@ fn void test(Rectangle r) /* #expect: foo.ll -define void @foo_test(<2 x float> %0, <2 x float> %1) #0 { +define void @foo.test(<2 x float> %0, <2 x float> %1) #0 { entry: %r = alloca %Rectangle, align 8 %literal = alloca %Rectangle, align 4 @@ -37,6 +37,6 @@ entry: %lo = load <2 x float>, ptr %6, align 8 %7 = getelementptr inbounds { <2 x float>, <2 x float> }, ptr %coerce, i32 0, i32 1 %hi = load <2 x float>, ptr %7, align 8 - call void @foo_test(<2 x float> %lo, <2 x float> %hi) + call void @foo.test(<2 x float> %lo, <2 x float> %hi) ret void } \ No newline at end of file diff --git a/test/test_suite/abi/test_sret.c3t b/test/test_suite/abi/test_sret.c3t index 39eb03e04..3ec4addaf 100644 --- a/test/test_suite/abi/test_sret.c3t +++ b/test/test_suite/abi/test_sret.c3t @@ -22,7 +22,7 @@ declare void @foo1(ptr noalias sret(%Abc) align 8) #0 declare void @foo2(ptr noalias sret(%Abc) align 8) #0 -define void @test_sret_bar() #0 { +define void @test_sret.bar() #0 { entry: %dummy1 = alloca %Abc, align 8 %dummy2 = alloca %Abc, align 8 diff --git a/test/test_suite/abi/union_x64.c3t b/test/test_suite/abi/union_x64.c3t index 030759305..614b46be6 100644 --- a/test/test_suite/abi/union_x64.c3t +++ b/test/test_suite/abi/union_x64.c3t @@ -20,7 +20,7 @@ fn void hello(Foo f) declare void @hello2(i64, i64) #0 -define void @unionx64_hello(i64 %0, i64 %1) #0 { +define void @unionx64.hello(i64 %0, i64 %1) #0 { entry: %f = alloca %Foo, align 8 store i64 %0, ptr %f, align 8 diff --git a/test/test_suite/abi/x64alignarray.c3t b/test/test_suite/abi/x64alignarray.c3t index 8c4ee8a6b..892d45fe0 100644 --- a/test/test_suite/abi/x64alignarray.c3t +++ b/test/test_suite/abi/x64alignarray.c3t @@ -11,7 +11,7 @@ fn void test1_g() /* #expect: test.ll -define void @test_test1_g() #0 { +define void @test.test1_g() #0 { entry: %x = alloca [4 x float], align 16 %0 = getelementptr inbounds [4 x float], ptr %x, i64 0, i64 0 diff --git a/test/test_suite/arrays/array_casts.c3t b/test/test_suite/arrays/array_casts.c3t index e2b7065c3..04c31c96b 100644 --- a/test/test_suite/arrays/array_casts.c3t +++ b/test/test_suite/arrays/array_casts.c3t @@ -13,7 +13,7 @@ fn void test() %"int[]" = type { ptr, i64 } -define void @array_casts_test() #0 { +define void @array_casts.test() #0 { entry: %x = alloca [3 x i32], align 4 %y = alloca ptr, align 8 diff --git a/test/test_suite/arrays/array_comparison.c3t b/test/test_suite/arrays/array_comparison.c3t index 109d5a155..57eb87003 100644 --- a/test/test_suite/arrays/array_comparison.c3t +++ b/test/test_suite/arrays/array_comparison.c3t @@ -62,7 +62,7 @@ fn void test2() /* #expect: test.ll -define void @test_test() #0 { +define void @test.test() #0 { entry: %a = alloca [2 x double], align 16 %b = alloca [2 x double], align 16 @@ -224,7 +224,7 @@ exit30: ; preds = %match29, %next_chec store i8 %61, ptr %y3, align 1 ret void } -define void @test_test2() #0 { +define void @test.test2() #0 { entry: %a = alloca [200 x double], align 16 %b = alloca [200 x double], align 16 diff --git a/test/test_suite/arrays/array_literal.c3t b/test/test_suite/arrays/array_literal.c3t index d29dd766e..615efc65b 100644 --- a/test/test_suite/arrays/array_literal.c3t +++ b/test/test_suite/arrays/array_literal.c3t @@ -16,7 +16,7 @@ fn double test(uint x) @.__const = private unnamed_addr constant [30 x double] [double 0.000000e+00, double 1.270600e+01, double 4.303000e+00, double 3.182000e+00, double 2.776000e+00, double 2.571000e+00, double 2.447000e+00, double 2.365000e+00, double 2.306000e+00, double 2.262000e+00, double 2.228000e+00, double 2.201000e+00, double 2.179000e+00, double 2.160000e+00, double 2.145000e+00, double 2.131000e+00, double 2.120000e+00, double 2.110000e+00, double 2.101000e+00, double 2.093000e+00, double 2.086000e+00, double 2.080000e+00, double 2.074000e+00, double 2.069000e+00, double 2.064000e+00, double 2.060000e+00, double 2.056000e+00, double 2.052000e+00, double 2.048000e+00, double 2.045000e+00], align 16 -define double @array_literal_test(i32 %0) #0 { +define double @array_literal.test(i32 %0) #0 { entry: %student_t = alloca [30 x double], align 16 call void @llvm.memcpy.p0.p0.i32(ptr align 16 %student_t, ptr align 16 @.__const, i32 240, i1 false) diff --git a/test/test_suite/arrays/array_struct.c3t b/test/test_suite/arrays/array_struct.c3t index ad1ef0df0..0bc58913a 100644 --- a/test/test_suite/arrays/array_struct.c3t +++ b/test/test_suite/arrays/array_struct.c3t @@ -10,4 +10,4 @@ Foo[10] array @private; // #expect: test.ll -@test_array = protected unnamed_addr global [10 x %Foo] zeroinitializer, align 16 \ No newline at end of file +@test.array = protected unnamed_addr global [10 x %Foo] zeroinitializer, align 16 \ No newline at end of file diff --git a/test/test_suite/arrays/complex_array_const.c3t b/test/test_suite/arrays/complex_array_const.c3t index 2386c21c9..bc1dda804 100644 --- a/test/test_suite/arrays/complex_array_const.c3t +++ b/test/test_suite/arrays/complex_array_const.c3t @@ -15,8 +15,8 @@ Connection[3] link @private /* #expect: test.ll -@"ct$test_Connection" = linkonce constant %.introspect { i8 10, i64 24, i64 0, i64 3, [0 x i64] zeroinitializer }, align 8 +@"ct$test.Connection" = linkonce constant %.introspect { i8 10, i64 24, i64 0, i64 3, [0 x i64] zeroinitializer }, align 8 @.str = private unnamed_addr constant [6 x i8] c"link1\00", align 1 @.str.1 = private unnamed_addr constant [6 x i8] c"link2\00", align 1 @.str.2 = private unnamed_addr constant [6 x i8] c"link3\00", align 1 -@test_link = protected unnamed_addr global [3 x %Connection] [%Connection { i64 1, ptr @.str, i64 10 }, %Connection { i64 2, ptr @.str.1, i64 20 }, %Connection { i64 3, ptr @.str.2, i64 30 }], align 16 +@test.link = protected unnamed_addr global [3 x %Connection] [%Connection { i64 1, ptr @.str, i64 10 }, %Connection { i64 2, ptr @.str.1, i64 20 }, %Connection { i64 3, ptr @.str.2, i64 30 }], align 16 diff --git a/test/test_suite/arrays/global_init.c3t b/test/test_suite/arrays/global_init.c3t index 88698f917..872d6f44c 100644 --- a/test/test_suite/arrays/global_init.c3t +++ b/test/test_suite/arrays/global_init.c3t @@ -21,28 +21,28 @@ fn void main() { /* #expect: test.ll @.taddr = private global i32 3, align 4 -@test_foo = local_unnamed_addr global ptr @.taddr, align 8 -@test_a = global i32 0, align 4 -@test_c = local_unnamed_addr global i32 0, align 4 -@test_d = local_unnamed_addr global i32 0, align 4 -@test_abc = local_unnamed_addr global [3 x i32] zeroinitializer, align 4 -@test_b = local_unnamed_addr global ptr getelementptr (i32, ptr @test_a, i64 7), align 8 -@test_bf = local_unnamed_addr global ptr getelementptr ([3 x i32], ptr @test_abc, i64 1, i64 1), align 8 -@test_bf2 = local_unnamed_addr global ptr getelementptr inbounds ([3 x i32], ptr @test_abc, i64 0, i64 2), align 8 -@test_bf3 = local_unnamed_addr global ptr getelementptr ([3 x i32], ptr @test_abc, i64 1, i64 1), align 8 +@test.foo = local_unnamed_addr global ptr @.taddr, align 8 +@test.a = global i32 0, align 4 +@test.c = local_unnamed_addr global i32 0, align 4 +@test.d = local_unnamed_addr global i32 0, align 4 +@test.abc = local_unnamed_addr global [3 x i32] zeroinitializer, align 4 +@test.b = local_unnamed_addr global ptr getelementptr (i32, ptr @test.a, i64 7), align 8 +@test.bf = local_unnamed_addr global ptr getelementptr ([3 x i32], ptr @test.abc, i64 1, i64 1), align 8 +@test.bf2 = local_unnamed_addr global ptr getelementptr inbounds ([3 x i32], ptr @test.abc, i64 0, i64 2), align 8 +@test.bf3 = local_unnamed_addr global ptr getelementptr ([3 x i32], ptr @test.abc, i64 1, i64 1), align 8 @.taddr.9 = private global i32 42, align 4 @.taddr.10 = private global i8 99, align 1 @.taddr.11 = private global ptr @.str, align 8 @"main$x" = internal unnamed_addr global [3 x %variant] [%variant { ptr @.taddr.9, i64 ptrtoint (ptr @"ct$int" to i64) }, %variant { ptr @.taddr.10, i64 ptrtoint (ptr @"ct$char" to i64) }, %variant { ptr @.taddr.11, i64 ptrtoint (ptr @"ct$p$a3$char" to i64) }], align 16 -define void @test_main() #0 { +define void @test.main() #0 { entry: %bf34 = alloca ptr, align 8 %y = alloca [3 x %variant], align 16 %taddr = alloca i32, align 4 %taddr1 = alloca i8, align 1 %taddr2 = alloca ptr, align 8 - store ptr getelementptr ([3 x i32], ptr @test_abc, i64 2, i64 1), ptr %bf34, align 8 + store ptr getelementptr ([3 x i32], ptr @test.abc, i64 2, i64 1), ptr %bf34, align 8 %0 = getelementptr inbounds [3 x %variant], ptr %y, i64 0, i64 0 store i32 42, ptr %taddr, align 4 %1 = insertvalue %variant undef, ptr %taddr, 0 diff --git a/test/test_suite/arrays/index_from_back.c3t b/test/test_suite/arrays/index_from_back.c3t index 32a1f13c3..b91ba565c 100644 --- a/test/test_suite/arrays/index_from_back.c3t +++ b/test/test_suite/arrays/index_from_back.c3t @@ -15,7 +15,7 @@ fn void test(int[10] x, int[<10>] y) /* #expect: test.ll -define void @test_test(ptr byval([10 x i32]) align 8 %0, ptr byval(<10 x i32>) align 64 %1) #0 { +define void @test.test(ptr byval([10 x i32]) align 8 %0, ptr byval(<10 x i32>) align 64 %1) #0 { entry: %a = alloca i32, align 4 %b = alloca i32, align 4 diff --git a/test/test_suite/arrays/index_into_global.c3t b/test/test_suite/arrays/index_into_global.c3t index 8c107bea6..544e7c53e 100644 --- a/test/test_suite/arrays/index_into_global.c3t +++ b/test/test_suite/arrays/index_into_global.c3t @@ -22,12 +22,12 @@ fn void test_bar(int idx) /* #expect: foo.ll -define void @foo_test_bar(i32 %0) #0 { +define void @foo.test_bar(i32 %0) #0 { entry: %sisiext = sext i32 %0 to i64 - %1 = getelementptr inbounds [6 x %Bar], ptr @foo_bar, i64 0, i64 %sisiext + %1 = getelementptr inbounds [6 x %Bar], ptr @foo.bar, i64 0, i64 %sisiext %2 = getelementptr inbounds %Bar, ptr %1, i32 0, i32 0 store i32 0, ptr %2, align 4 - store i32 %0, ptr @foo_bar, align 4 + store i32 %0, ptr @foo.bar, align 4 ret void } diff --git a/test/test_suite/assert/assert_variants.c3t b/test/test_suite/assert/assert_variants.c3t index f9f8a5a32..fa9add3f5 100644 --- a/test/test_suite/assert/assert_variants.c3t +++ b/test/test_suite/assert/assert_variants.c3t @@ -24,11 +24,11 @@ fn void test() %x = alloca i32, align 4 %y = alloca i32, align 4 %z = alloca i32, align 4 - %0 = call i32 @assert_variants_foo() + %0 = call i32 @assert_variants.foo() store i32 %0, ptr %x, align 4 - %1 = call i32 @assert_variants_foo() + %1 = call i32 @assert_variants.foo() store i32 %1, ptr %y, align 4 - %2 = call i32 @assert_variants_foo() + %2 = call i32 @assert_variants.foo() store i32 %2, ptr %z, align 4 %3 = load i32, ptr %x, align 4 %gt = icmp sgt i32 %3, 0 diff --git a/test/test_suite/assert/unreachable.c3t b/test/test_suite/assert/unreachable.c3t index 48eb633e5..6fa672e11 100644 --- a/test/test_suite/assert/unreachable.c3t +++ b/test/test_suite/assert/unreachable.c3t @@ -15,10 +15,10 @@ fn void test() /* #expect: unreachable.ll -define void @unreachable_test() #0 { +define void @unreachable.test() #0 { entry: %x = alloca i32, align 4 - %0 = call i32 @unreachable_foo() + %0 = call i32 @unreachable.foo() store i32 %0, ptr %x, align 4 %1 = load i32, ptr %x, align 4 %gt = icmp sgt i32 %1, 0 @@ -28,7 +28,7 @@ if.then: ; preds = %entry ret void if.exit: ; preds = %entry - %2 = load ptr, ptr @std_core_builtin_panic, align 8 + %2 = load ptr, ptr @std_core_builtin.panic, align 8 call void %2(ptr @.str, i64 30, ptr @.str.1, i64 14, ptr @.str.2, i64 4, i32 10) unreachable diff --git a/test/test_suite/attributes/attribute_visibility.c3t b/test/test_suite/attributes/attribute_visibility.c3t index cab75cafe..227f045ae 100644 --- a/test/test_suite/attributes/attribute_visibility.c3t +++ b/test/test_suite/attributes/attribute_visibility.c3t @@ -9,4 +9,4 @@ int black @Align(16) = 123; /* #expect: test2.ll -@test2_black = local_unnamed_addr global i32 123, align 64 \ No newline at end of file +@test2.black = local_unnamed_addr global i32 123, align 64 \ No newline at end of file diff --git a/test/test_suite/attributes/user_defined_attributes.c3t b/test/test_suite/attributes/user_defined_attributes.c3t index ffb6da25d..3aa1549db 100644 --- a/test/test_suite/attributes/user_defined_attributes.c3t +++ b/test/test_suite/attributes/user_defined_attributes.c3t @@ -32,24 +32,24 @@ fn void main() @TestZero /* #expect: test.ll %Foo = type { i32, [1020 x i8], i32, [1020 x i8] } -@"ct$test_Foo" = linkonce constant %.introspect { i8 10, i64 2048, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 -@test_f = local_unnamed_addr global %Foo zeroinitializer, align 1024 +@"ct$test.Foo" = linkonce constant %.introspect { i8 10, i64 2048, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 +@test.f = local_unnamed_addr global %Foo zeroinitializer, align 1024 -define weak void @test_testme2() #0 { +define weak void @test.testme2() #0 { entry: ret void } -define void @test_testme() #1 { +define void @test.testme() #1 { entry: %x = alloca i32, align 4 store i32 0, ptr %x, align 4 ret void } -define void @test_main() #2 { +define void @test.main() #2 { entry: - call void @test_testme() + call void @test.testme() ret void } attributes #0 = { noreturn nounwind } diff --git a/test/test_suite/bitstruct/array_with_boolean.c3t b/test/test_suite/bitstruct/array_with_boolean.c3t index 9f5c4224c..5930c0f4a 100644 --- a/test/test_suite/bitstruct/array_with_boolean.c3t +++ b/test/test_suite/bitstruct/array_with_boolean.c3t @@ -23,7 +23,7 @@ fn void main() /* #expect: foo.ll -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %xx = alloca [3 x i8], align 1 %xy = alloca [3 x i8], align 1 diff --git a/test/test_suite/bitstruct/bitfield_access.c3t b/test/test_suite/bitstruct/bitfield_access.c3t index b22e6e031..9cf494182 100644 --- a/test/test_suite/bitstruct/bitfield_access.c3t +++ b/test/test_suite/bitstruct/bitfield_access.c3t @@ -93,7 +93,7 @@ fn void main() /* #expect: foo.ll -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %b = alloca i8, align 1 %c1 = alloca i16, align 2 diff --git a/test/test_suite/bitstruct/bitstruct_access_signed.c3t b/test/test_suite/bitstruct/bitstruct_access_signed.c3t index 3475821f5..8141d500b 100644 --- a/test/test_suite/bitstruct/bitstruct_access_signed.c3t +++ b/test/test_suite/bitstruct/bitstruct_access_signed.c3t @@ -30,7 +30,7 @@ fn void main() /* #expect: foo.ll -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %xx = alloca [3 x i8], align 1 %xxu = alloca [3 x i8], align 1 diff --git a/test/test_suite/bitstruct/bitstruct_arrays.c3t b/test/test_suite/bitstruct/bitstruct_arrays.c3t index 066ba1e77..fe4def452 100644 --- a/test/test_suite/bitstruct/bitstruct_arrays.c3t +++ b/test/test_suite/bitstruct/bitstruct_arrays.c3t @@ -122,7 +122,7 @@ fn void test3() /* #expect: foo.ll -define void @foo_test1() #0 { +define void @foo.test1() #0 { entry: %xx = alloca i64, align 8 store i64 531994, ptr %xx, align 8 @@ -333,7 +333,7 @@ entry: } ; Function Attrs: nounwind -define void @foo_test2() #0 { +define void @foo.test2() #0 { entry: %xx = alloca [3 x i8], align 1 store [3 x i8] c"\1A\1E\00", ptr %xx, align 1 @@ -730,7 +730,7 @@ entry: } ; Function Attrs: nounwind -define void @foo_test3() #0 { +define void @foo.test3() #0 { entry: %xx = alloca [3 x i8], align 1 store [3 x i8] c"4<\00", ptr %xx, align 1 diff --git a/test/test_suite/bitstruct/bitstruct_arrays_be.c3t b/test/test_suite/bitstruct/bitstruct_arrays_be.c3t index d2325338b..d90c3131e 100644 --- a/test/test_suite/bitstruct/bitstruct_arrays_be.c3t +++ b/test/test_suite/bitstruct/bitstruct_arrays_be.c3t @@ -37,7 +37,7 @@ fn void test3() /* #expect: foo.ll -define void @foo_test3() #0 { +define void @foo.test3() #0 { entry: %xx = alloca [4 x i8], align 1 %xy = alloca [4 x i8], align 1 diff --git a/test/test_suite/bitstruct/bitstruct_be.c3t b/test/test_suite/bitstruct/bitstruct_be.c3t index 8224b9455..f2339d7ff 100644 --- a/test/test_suite/bitstruct/bitstruct_be.c3t +++ b/test/test_suite/bitstruct/bitstruct_be.c3t @@ -57,7 +57,7 @@ fn void main() %8 = insertvalue %variant %7, i64 ptrtoint (ptr @"ct$int" to i64), 1 %9 = getelementptr inbounds [2 x %variant], ptr %varargslots, i64 0, i64 1 store %variant %8, ptr %9, align 16 - %10 = call i64 @std_io_printf(ptr %retparam, ptr @.str, i64 18, ptr %varargslots, i64 2) + %10 = call i64 @std_io.printf(ptr %retparam, ptr @.str, i64 18, ptr %varargslots, i64 2) store i32 873625686, ptr %abc, align 4 store [4 x i8] c"\124Vx", ptr %abc2, align 1 store ptr %abc, ptr %z, align 8 @@ -82,7 +82,7 @@ loop.body: ; preds = %loop.cond %18 = insertvalue %variant %17, i64 ptrtoint (ptr @"ct$char" to i64), 1 %19 = getelementptr inbounds [1 x %variant], ptr %varargslots3, i64 0, i64 0 store %variant %18, ptr %19, align 16 - %20 = call i64 @std_io_printf(ptr %retparam2, ptr @.str.1, i64 3, ptr %varargslots3, i64 1) + %20 = call i64 @std_io.printf(ptr %retparam2, ptr @.str.1, i64 3, ptr %varargslots3, i64 1) %21 = load i64, ptr %.anon1, align 8 %add = add i64 %21, 1 store i64 %add, ptr %.anon1, align 8 @@ -90,9 +90,9 @@ loop.body: ; preds = %loop.cond loop.exit: ; preds = %loop.cond store ptr @.str.2, ptr %x4, align 8 - %22 = call ptr @std_io_stdout() + %22 = call ptr @std_io.stdout() store ptr %22, ptr %result, align 8 - %23 = call i64 @std_io_File_printn(ptr %retparam5, ptr %result, ptr null, i64 0) + %23 = call i64 @std_io.File_printn(ptr %retparam5, ptr %result, ptr null, i64 0) %24 = load ptr, ptr %z, align 8 store ptr %24, ptr %.anon6, align 8 store i64 0, ptr %.anon7, align 8 @@ -113,7 +113,7 @@ loop.body10: ; preds = %loop.cond8 %31 = insertvalue %variant %30, i64 ptrtoint (ptr @"ct$char" to i64), 1 %32 = getelementptr inbounds [1 x %variant], ptr %varargslots13, i64 0, i64 0 store %variant %31, ptr %32, align 16 - %33 = call i64 @std_io_printf(ptr %retparam12, ptr @.str.3, i64 3, ptr %varargslots13, i64 1) + %33 = call i64 @std_io.printf(ptr %retparam12, ptr @.str.3, i64 3, ptr %varargslots13, i64 1) %34 = load i64, ptr %.anon7, align 8 %add14 = add i64 %34, 1 store i64 %add14, ptr %.anon7, align 8 @@ -121,9 +121,9 @@ loop.body10: ; preds = %loop.cond8 loop.exit15: ; preds = %loop.cond8 store ptr @.str.4, ptr %x16, align 8 - %35 = call ptr @std_io_stdout() + %35 = call ptr @std_io.stdout() store ptr %35, ptr %result18, align 8 - %36 = call i64 @std_io_File_printn(ptr %retparam17, ptr %result18, ptr null, i64 0) + %36 = call i64 @std_io.File_printn(ptr %retparam17, ptr %result18, ptr null, i64 0) %37 = load i32, ptr %abc, align 4 %38 = call i32 @llvm.bswap.i32(i32 %37) %39 = and i32 65535, %38 @@ -133,7 +133,7 @@ loop.exit15: ; preds = %loop.cond8 %41 = insertvalue %variant %40, i64 ptrtoint (ptr @"ct$ushort" to i64), 1 %42 = getelementptr inbounds [1 x %variant], ptr %varargslots20, i64 0, i64 0 store %variant %41, ptr %42, align 16 - %43 = call i64 @std_io_printfn(ptr %retparam19, ptr @.str.5, i64 10, ptr %varargslots20, i64 1) + %43 = call i64 @std_io.printfn(ptr %retparam19, ptr @.str.5, i64 10, ptr %varargslots20, i64 1) %44 = load i32, ptr %abc, align 4 %45 = call i32 @llvm.bswap.i32(i32 %44) %46 = and i32 %45, -65536 @@ -155,7 +155,7 @@ loop.exit15: ; preds = %loop.cond8 %58 = insertvalue %variant %57, i64 ptrtoint (ptr @"ct$ushort" to i64), 1 %59 = getelementptr inbounds [1 x %variant], ptr %varargslots23, i64 0, i64 0 store %variant %58, ptr %59, align 16 - %60 = call i64 @std_io_printfn(ptr %retparam22, ptr @.str.6, i64 12, ptr %varargslots23, i64 1) + %60 = call i64 @std_io.printfn(ptr %retparam22, ptr @.str.6, i64 12, ptr %varargslots23, i64 1) %61 = load ptr, ptr %z, align 8 store ptr %61, ptr %.anon26, align 8 store i64 0, ptr %.anon27, align 8 @@ -176,7 +176,7 @@ loop.body30: ; preds = %loop.cond28 %68 = insertvalue %variant %67, i64 ptrtoint (ptr @"ct$char" to i64), 1 %69 = getelementptr inbounds [1 x %variant], ptr %varargslots33, i64 0, i64 0 store %variant %68, ptr %69, align 16 - %70 = call i64 @std_io_printf(ptr %retparam32, ptr @.str.7, i64 3, ptr %varargslots33, i64 1) + %70 = call i64 @std_io.printf(ptr %retparam32, ptr @.str.7, i64 3, ptr %varargslots33, i64 1) %71 = load i64, ptr %.anon27, align 8 %add34 = add i64 %71, 1 store i64 %add34, ptr %.anon27, align 8 @@ -184,9 +184,9 @@ loop.body30: ; preds = %loop.cond28 loop.exit35: ; preds = %loop.cond28 store ptr @.str.8, ptr %x36, align 8 - %72 = call ptr @std_io_stdout() + %72 = call ptr @std_io.stdout() store ptr %72, ptr %result38, align 8 - %73 = call i64 @std_io_File_printn(ptr %retparam37, ptr %result38, ptr null, i64 0) + %73 = call i64 @std_io.File_printn(ptr %retparam37, ptr %result38, ptr null, i64 0) store i32 0, ptr %y, align 4 %74 = load i32, ptr %y, align 4 store i32 123, ptr %y, align 4 @@ -200,6 +200,6 @@ loop.exit35: ; preds = %loop.cond28 %80 = insertvalue %variant %79, i64 ptrtoint (ptr @"ct$int" to i64), 1 %81 = getelementptr inbounds [2 x %variant], ptr %varargslots40, i64 0, i64 1 store %variant %80, ptr %81, align 16 - %82 = call i64 @std_io_printf(ptr %retparam39, ptr @.str.9, i64 18, ptr %varargslots40, i64 2) + %82 = call i64 @std_io.printf(ptr %retparam39, ptr @.str.9, i64 18, ptr %varargslots40, i64 2) ret void } \ No newline at end of file diff --git a/test/test_suite/bitstruct/bitstruct_init_bool.c3t b/test/test_suite/bitstruct/bitstruct_init_bool.c3t index 36cc64886..e91b63457 100644 --- a/test/test_suite/bitstruct/bitstruct_init_bool.c3t +++ b/test/test_suite/bitstruct/bitstruct_init_bool.c3t @@ -14,7 +14,7 @@ fn void test() /* #expect: foo.ll -define void @foo_test() #0 { +define void @foo.test() #0 { entry: %f = alloca i32, align 4 store i32 2, ptr %f, align 4 diff --git a/test/test_suite/bitstruct/bitstruct_initializer.c3t b/test/test_suite/bitstruct/bitstruct_initializer.c3t index 319600465..1ba9f3152 100644 --- a/test/test_suite/bitstruct/bitstruct_initializer.c3t +++ b/test/test_suite/bitstruct/bitstruct_initializer.c3t @@ -48,7 +48,7 @@ fn void main() /* #expect: test.ll -define void @test_hello(i32 %0) #0 { +define void @test.hello(i32 %0) #0 { entry: %x = alloca i64, align 8 %y = alloca %Abc, align 8 @@ -179,7 +179,7 @@ entry: %44 = insertvalue %variant %43, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %45 = getelementptr inbounds [3 x %variant], ptr %varargslots, i64 0, i64 2 store %variant %44, ptr %45, align 16 - %46 = call i64 @std_io_printfn(ptr %retparam, ptr @.str, i64 8, ptr %varargslots, i64 3) + %46 = call i64 @std_io.printfn(ptr %retparam, ptr @.str, i64 8, ptr %varargslots, i64 3) %47 = getelementptr inbounds %Abc, ptr %y, i32 0, i32 1 %48 = load i64, ptr %47, align 8 %49 = and i64 4294967295, %48 @@ -209,7 +209,7 @@ entry: %63 = insertvalue %variant %62, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %64 = getelementptr inbounds [3 x %variant], ptr %varargslots18, i64 0, i64 2 store %variant %63, ptr %64, align 16 - %65 = call i64 @std_io_printfn(ptr %retparam17, ptr @.str.2, i64 8, ptr %varargslots18, i64 3) + %65 = call i64 @std_io.printfn(ptr %retparam17, ptr @.str.2, i64 8, ptr %varargslots18, i64 3) %66 = getelementptr inbounds [8 x i8], ptr %b, i64 0, i64 0 %67 = load i8, ptr %66, align 1 %zext29 = zext i8 %67 to i32 @@ -267,7 +267,7 @@ entry: %100 = insertvalue %variant %99, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %101 = getelementptr inbounds [3 x %variant], ptr %varargslots28, i64 0, i64 2 store %variant %100, ptr %101, align 16 - %102 = call i64 @std_io_printfn(ptr %retparam27, ptr @.str.3, i64 8, ptr %varargslots28, i64 3) + %102 = call i64 @std_io.printfn(ptr %retparam27, ptr @.str.3, i64 8, ptr %varargslots28, i64 3) %add = add i32 %0, 1 %zext47 = zext i32 %add to i64 %103 = and i64 %zext47, 4294967295 @@ -360,7 +360,7 @@ entry: %147 = insertvalue %variant %146, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %148 = getelementptr inbounds [3 x %variant], ptr %varargslots62, i64 0, i64 2 store %variant %147, ptr %148, align 16 - %149 = call i64 @std_io_printfn(ptr %retparam61, ptr @.str.4, i64 8, ptr %varargslots62, i64 3) + %149 = call i64 @std_io.printfn(ptr %retparam61, ptr @.str.4, i64 8, ptr %varargslots62, i64 3) %150 = getelementptr inbounds %Abc, ptr %y, i32 0, i32 1 %151 = load i64, ptr %150, align 8 %152 = and i64 4294967295, %151 @@ -390,7 +390,7 @@ entry: %166 = insertvalue %variant %165, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %167 = getelementptr inbounds [3 x %variant], ptr %varargslots72, i64 0, i64 2 store %variant %166, ptr %167, align 16 - %168 = call i64 @std_io_printfn(ptr %retparam71, ptr @.str.5, i64 8, ptr %varargslots72, i64 3) + %168 = call i64 @std_io.printfn(ptr %retparam71, ptr @.str.5, i64 8, ptr %varargslots72, i64 3) %169 = getelementptr inbounds [8 x i8], ptr %b, i64 0, i64 0 %170 = load i8, ptr %169, align 1 %zext83 = zext i8 %170 to i32 @@ -448,13 +448,13 @@ entry: %203 = insertvalue %variant %202, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %204 = getelementptr inbounds [3 x %variant], ptr %varargslots82, i64 0, i64 2 store %variant %203, ptr %204, align 16 - %205 = call i64 @std_io_printfn(ptr %retparam81, ptr @.str.6, i64 8, ptr %varargslots82, i64 3) + %205 = call i64 @std_io.printfn(ptr %retparam81, ptr @.str.6, i64 8, ptr %varargslots82, i64 3) ret void } ; Function Attrs: nounwind -define void @test_main() #0 { +define void @test.main() #0 { entry: - call void @test_hello(i32 12) + call void @test.hello(i32 12) ret void } diff --git a/test/test_suite/bitstruct/bitstruct_ops.c3t b/test/test_suite/bitstruct/bitstruct_ops.c3t index 158499f65..8bfbe5329 100644 --- a/test/test_suite/bitstruct/bitstruct_ops.c3t +++ b/test/test_suite/bitstruct/bitstruct_ops.c3t @@ -42,7 +42,7 @@ fn void main() /* #expect: test.ll -define void @test_main() #0 { +define void @test.main() #0 { entry: %f1 = alloca i32, align 4 %f2 = alloca i32, align 4 @@ -110,7 +110,7 @@ entry: %13 = insertvalue %variant %12, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %14 = getelementptr inbounds [2 x %variant], ptr %varargslots, i64 0, i64 1 store %variant %13, ptr %14, align 16 - %15 = call i64 @std_io_printfn(ptr %retparam, ptr @.str, i64 5, ptr %varargslots, i64 2) + %15 = call i64 @std_io.printfn(ptr %retparam, ptr @.str, i64 5, ptr %varargslots, i64 2) %16 = load i32, ptr %f1, align 4 %17 = load i32, ptr %f2, align 4 %bnot = xor i32 %17, -1 @@ -135,7 +135,7 @@ entry: %27 = insertvalue %variant %26, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %28 = getelementptr inbounds [2 x %variant], ptr %varargslots4, i64 0, i64 1 store %variant %27, ptr %28, align 16 - %29 = call i64 @std_io_printfn(ptr %retparam3, ptr @.str.1, i64 5, ptr %varargslots4, i64 2) + %29 = call i64 @std_io.printfn(ptr %retparam3, ptr @.str.1, i64 5, ptr %varargslots4, i64 2) store i32 3, ptr %f5, align 4 %30 = load i32, ptr %f5, align 4 %31 = and i32 1, %30 @@ -154,7 +154,7 @@ entry: %38 = insertvalue %variant %37, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %39 = getelementptr inbounds [2 x %variant], ptr %varargslots11, i64 0, i64 1 store %variant %38, ptr %39, align 16 - %40 = call i64 @std_io_printfn(ptr %retparam10, ptr @.str.2, i64 5, ptr %varargslots11, i64 2) + %40 = call i64 @std_io.printfn(ptr %retparam10, ptr @.str.2, i64 5, ptr %varargslots11, i64 2) %41 = load i32, ptr %f5, align 4 %42 = load i32, ptr %f2, align 4 %and17 = and i32 %41, %42 @@ -176,7 +176,7 @@ entry: %51 = insertvalue %variant %50, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %52 = getelementptr inbounds [2 x %variant], ptr %varargslots19, i64 0, i64 1 store %variant %51, ptr %52, align 16 - %53 = call i64 @std_io_printfn(ptr %retparam18, ptr @.str.3, i64 5, ptr %varargslots19, i64 2) + %53 = call i64 @std_io.printfn(ptr %retparam18, ptr @.str.3, i64 5, ptr %varargslots19, i64 2) store [13 x i8] c"\03\00\00\02\00\00\00\00\00\00\00\00\00", ptr %b1, align 1 store [13 x i8] c"\01\00\00\00\00\00\00\00\00\00\00\00\00", ptr %b2, align 1 %54 = load i104, ptr %b1, align 1 @@ -213,7 +213,7 @@ entry: %75 = insertvalue %variant %74, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %76 = getelementptr inbounds [3 x %variant], ptr %varargslots27, i64 0, i64 2 store %variant %75, ptr %76, align 16 - %77 = call i64 @std_io_printfn(ptr %retparam26, ptr @.str.4, i64 8, ptr %varargslots27, i64 3) + %77 = call i64 @std_io.printfn(ptr %retparam26, ptr @.str.4, i64 8, ptr %varargslots27, i64 3) %78 = load i104, ptr %b3, align 1 %bnot33 = xor i104 %78, -1 store i104 %bnot33, ptr %1, align 8 @@ -247,7 +247,7 @@ entry: %98 = insertvalue %variant %97, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %99 = getelementptr inbounds [3 x %variant], ptr %varargslots35, i64 0, i64 2 store %variant %98, ptr %99, align 16 - %100 = call i64 @std_io_printfn(ptr %retparam34, ptr @.str.5, i64 8, ptr %varargslots35, i64 3) + %100 = call i64 @std_io.printfn(ptr %retparam34, ptr @.str.5, i64 8, ptr %varargslots35, i64 3) store [13 x i8] c"\03\00\00\00\00\00\00\00\00\00\00\00\00", ptr %taddr41, align 1 %101 = load i104, ptr %b3, align 1 %102 = load i104, ptr %taddr41, align 1 @@ -283,6 +283,6 @@ entry: %122 = insertvalue %variant %121, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %123 = getelementptr inbounds [3 x %variant], ptr %varargslots44, i64 0, i64 2 store %variant %122, ptr %123, align 16 - %124 = call i64 @std_io_printfn(ptr %retparam43, ptr @.str.6, i64 8, ptr %varargslots44, i64 3) + %124 = call i64 @std_io.printfn(ptr %retparam43, ptr @.str.6, i64 8, ptr %varargslots44, i64 3) ret void } diff --git a/test/test_suite/bitstruct/bitstruct_to_int.c3t b/test/test_suite/bitstruct/bitstruct_to_int.c3t index 0975a5a0a..c23d532ed 100644 --- a/test/test_suite/bitstruct/bitstruct_to_int.c3t +++ b/test/test_suite/bitstruct/bitstruct_to_int.c3t @@ -48,7 +48,7 @@ fn void main() /* #expect: foo.ll -define void @foo_test() #0 { +define void @foo.test() #0 { entry: %b = alloca i32, align 4 %x = alloca i32, align 4 @@ -74,7 +74,7 @@ entry: } ; Function Attrs: nounwind -define void @foo_test2() #0 { +define void @foo.test2() #0 { entry: %b = alloca [4 x i8], align 1 %x = alloca i32, align 4 diff --git a/test/test_suite/bitstruct/embedded_bitstruct.c3t b/test/test_suite/bitstruct/embedded_bitstruct.c3t index 580cf5a57..b8777f5b0 100644 --- a/test/test_suite/bitstruct/embedded_bitstruct.c3t +++ b/test/test_suite/bitstruct/embedded_bitstruct.c3t @@ -46,7 +46,7 @@ fn void main() /* #expect: foo.ll -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %b = alloca %Bar, align 4 %f = alloca %Foo, align 4 diff --git a/test/test_suite/bitstruct/param_bitstruct.c3t b/test/test_suite/bitstruct/param_bitstruct.c3t index 9a4d73336..61a580136 100644 --- a/test/test_suite/bitstruct/param_bitstruct.c3t +++ b/test/test_suite/bitstruct/param_bitstruct.c3t @@ -13,7 +13,7 @@ fn void test(Abc x) /* #expect: foo.ll -define void @foo_test(i32 %0) #0 { +define void @foo.test(i32 %0) #0 { entry: %x = alloca i32, align 4 store i32 %0, ptr %x, align 4 diff --git a/test/test_suite/builtins/shufflevector.c3t b/test/test_suite/builtins/shufflevector.c3t index d252a1711..2a9f09993 100644 --- a/test/test_suite/builtins/shufflevector.c3t +++ b/test/test_suite/builtins/shufflevector.c3t @@ -56,7 +56,7 @@ fn void main() /* #expect: test.ll -define double @test_apply3(ptr %0, double %1) #0 { +define double @test.apply3(ptr %0, double %1) #0 { entry: %vec = alloca <2 x float>, align 8 %a = alloca <2 x float>, align 8 diff --git a/test/test_suite/builtins/simple_builtins.c3t b/test/test_suite/builtins/simple_builtins.c3t index b603bebc1..3974480e4 100644 --- a/test/test_suite/builtins/simple_builtins.c3t +++ b/test/test_suite/builtins/simple_builtins.c3t @@ -19,7 +19,7 @@ fn int foo(double b) /* #expect: foo.ll -define i32 @foo_foo(double %0) #0 { +define i32 @foo.foo(double %0) #0 { entry: %d = alloca double, align 8 %e = alloca double, align 8 diff --git a/test/test_suite/cast/top_down_casts.c3t b/test/test_suite/cast/top_down_casts.c3t index 47c78e960..d1d56226b 100644 --- a/test/test_suite/cast/top_down_casts.c3t +++ b/test/test_suite/cast/top_down_casts.c3t @@ -17,7 +17,7 @@ fn void test() /* #expect: top_down_casts.ll -define void @top_down_casts_test() #0 { +define void @top_down_casts.test() #0 { entry: %x = alloca i32, align 4 %y = alloca i32, align 4 diff --git a/test/test_suite/clang/2002-01_02.c3t b/test/test_suite/clang/2002-01_02.c3t index 94597a61d..a5b594f83 100644 --- a/test/test_suite/clang/2002-01_02.c3t +++ b/test/test_suite/clang/2002-01_02.c3t @@ -140,31 +140,31 @@ void *[*] data = { &afoo, &abar, &axx }; %Test = type { i16, i16, i32, i32 } %STest2 = type { i32, [4 x i16], double } -@test_array = local_unnamed_addr global [10 x %Foo] zeroinitializer, align 16 -@test_afoo = global double 1.700000e+01, align 8 -@test_abar = global double 1.200000e+01, align 8 -@test_axx = global float 1.200000e+01, align 4 +@test.array = local_unnamed_addr global [10 x %Foo] zeroinitializer, align 16 +@test.afoo = global double 1.700000e+01, align 8 +@test.abar = global double 1.200000e+01, align 8 +@test.axx = global float 1.200000e+01, align 4 @.str = private unnamed_addr constant [5 x i8] c"EXIT\00", align 1 -@test_procnames = local_unnamed_addr global [1 x ptr] [ptr @.str], align 8 -@test_data = local_unnamed_addr global [3 x ptr] [ptr @test_afoo, ptr @test_abar, ptr @test_axx], align 16 +@test.procnames = local_unnamed_addr global [1 x ptr] [ptr @.str], align 8 +@test.data = local_unnamed_addr global [3 x ptr] [ptr @test.afoo, ptr @test.abar, ptr @test.axx], align 16 @.str.6 = private unnamed_addr constant [6 x i8] c"%lld\0A\00", align 1 -define void @test_foo() #0 { +define void @test.foo() #0 { entry: ret void } -declare ptr @test_dlclose(ptr) #0 +declare ptr @test.dlclose(ptr) #0 -define void @test_ap_os_dso_unload(ptr %0) #0 { +define void @test.ap_os_dso_unload(ptr %0) #0 { entry: - %1 = call ptr @test_dlclose(ptr %0) + %1 = call ptr @test.dlclose(ptr %0) ret void } declare void @foo2(i32, double, float) #0 -define void @test_bar(i32 %0) #0 { +define void @test.bar(i32 %0) #0 { entry: %intbool = icmp ne i32 %0, 0 %ternary = select i1 %intbool, double 1.000000e+00, double 1.250000e+01 @@ -174,7 +174,7 @@ entry: declare i32 @tolower(i32) #0 -define ptr @test_rangematch(ptr %0, i32 %1, i32 %2) #0 { +define ptr @test.rangematch(ptr %0, i32 %1, i32 %2) #0 { entry: %le = icmp sle i32 %2, %1 %3 = call i32 @tolower(i32 %2) @@ -192,7 +192,7 @@ if.exit: ; preds = %entry declare i32 @foo3(i16) #0 -define void @test_teste2() #0 { +define void @test.teste2() #0 { entry: %xqic = alloca %Foostruct, align 2 store i16 0, ptr %xqic, align 2 @@ -201,7 +201,7 @@ entry: ret void } -define i32 @test_do_merge(ptr %0, ptr %1) #0 { +define i32 @test.do_merge(ptr %0, ptr %1) #0 { entry: %lvalid = alloca i32, align 4 %basel = alloca ptr, align 8 @@ -226,22 +226,22 @@ loop.exit: ; No predecessors! ret i32 1 } -define i32 @test_test(i32 %0) #0 { +define i32 @test.test(i32 %0) #0 { entry: ret i32 %0 } -declare void @test_abc(ptr) #0 +declare void @test.abc(ptr) #0 -define i32 @test_def(i32 %0, i32 %1) #0 { +define i32 @test.def(i32 %0, i32 %1) #0 { entry: %z = alloca i32, align 4 store i32 %1, ptr %z, align 4 - call void @test_abc(ptr %z) + call void @test.abc(ptr %z) ret i32 %0 } -define i32 @test_testing(ptr %0) #0 { +define i32 @test.testing(ptr %0) #0 { entry: %1 = getelementptr inbounds %Test, ptr %0, i32 0, i32 1 %2 = load i16, ptr %1, align 2 @@ -252,7 +252,7 @@ entry: ret i32 %add } -define i32 @test_test2(i32 %0, i64 %1, i32 %2, i32 %3) #0 { +define i32 @test.test2(i32 %0, i64 %1, i32 %2, i32 %3) #0 { entry: %a = alloca %Test, align 8 store i64 %1, ptr %a, align 8 @@ -269,7 +269,7 @@ entry: ret i32 %add2 } -define i32 @test_test3(i64 %0, i32 %1, i64 %2, i32 %3) #0 { +define i32 @test.test3(i64 %0, i32 %1, i64 %2, i32 %3) #0 { entry: %a = alloca %Test, align 8 %b = alloca %Test, align 8 @@ -294,7 +294,7 @@ entry: ret i32 %add3 } -define { i64, i32 } @test_test4(i64 %0, i32 %1) #0 { +define { i64, i32 } @test.test4(i64 %0, i32 %1) #0 { entry: %a = alloca %Test, align 8 %tempcoerce = alloca { i64, i32 }, align 8 @@ -306,7 +306,7 @@ entry: ret { i64, i32 } %2 } -define i32 @test_test6() #0 { +define i32 @test.test6() #0 { entry: %b = alloca [200 x i32], align 16 call void @llvm.memset.p0.i64(ptr align 16 %b, i8 0, i64 800, i1 false) @@ -315,7 +315,7 @@ entry: ret i32 %1 } -define void @test_test7(ptr noalias sret(%STest2) align 8 %0, ptr byval(%STest2) align 8 %1) #0 { +define void @test.test7(ptr noalias sret(%STest2) align 8 %0, ptr byval(%STest2) align 8 %1) #0 { entry: call void @llvm.memcpy.p0.p0.i32(ptr align 8 %0, ptr align 8 %1, i32 24, i1 false) ret void @@ -323,7 +323,7 @@ entry: declare i32 @printf(ptr, ...) #0 -define i32 @test_main2() #0 { +define i32 @test.main2() #0 { entry: %v = alloca i64, align 8 store i64 123455678902, ptr %v, align 8 diff --git a/test/test_suite/clang/2002-03.c3t b/test/test_suite/clang/2002-03.c3t index 23afbbfc7..3bb280f67 100644 --- a/test/test_suite/clang/2002-03.c3t +++ b/test/test_suite/clang/2002-03.c3t @@ -53,25 +53,25 @@ fn char* foo() { /* #expect: test.ll -@test_a = local_unnamed_addr global { i32, i32, [8 x i32] } { i32 0, i32 2, [8 x i32] zeroinitializer }, align 16 -@test_str = local_unnamed_addr global [10 x i8] c"x\00\00\00\00\00\00\00\00\00", align 1 -@test_arr = local_unnamed_addr global { ptr, ptr, [3 x ptr] } zeroinitializer, align 16 -@test_f = local_unnamed_addr global { float, float, [10 x float] } { float 0x3FF3AE1480000000, float 0x40415999A0000000, [10 x float] zeroinitializer }, align 16 -@test_array = local_unnamed_addr global { %Test, %Test, [8 x %Test] } { %Test { i32 2, double 1.200000e+01 }, %Test { i32 3, double 2.400000e+01 }, [8 x %Test] zeroinitializer }, align 16 -@test_b = local_unnamed_addr global { [4 x i32], { i32, i32, i32, i32 }, { i32, i32, [2 x i32] }, [4 x i32] } { [4 x i32] [i32 1, i32 2, i32 3, i32 4], { i32, i32, i32, i32 } { i32 5, i32 6, i32 7, i32 0 }, { i32, i32, [2 x i32] } { i32 8, i32 9, [2 x i32] zeroinitializer }, [4 x i32] zeroinitializer }, align 16 -@test_link = local_unnamed_addr global [3 x %Connection] [%Connection { i64 1, [10 x i8] c"link1\00\00\00\00\00", i64 10 }, %Connection { i64 2, [10 x i8] c"link2\00\00\00\00\00", i64 20 }, %Connection { i64 3, [10 x i8] c"link3\00\00\00\00\00", i64 30 }], align 16 +@test.a = local_unnamed_addr global { i32, i32, [8 x i32] } { i32 0, i32 2, [8 x i32] zeroinitializer }, align 16 +@test.str = local_unnamed_addr global [10 x i8] c"x\00\00\00\00\00\00\00\00\00", align 1 +@test.arr = local_unnamed_addr global { ptr, ptr, [3 x ptr] } zeroinitializer, align 16 +@test.f = local_unnamed_addr global { float, float, [10 x float] } { float 0x3FF3AE1480000000, float 0x40415999A0000000, [10 x float] zeroinitializer }, align 16 +@test.array = local_unnamed_addr global { %Test, %Test, [8 x %Test] } { %Test { i32 2, double 1.200000e+01 }, %Test { i32 3, double 2.400000e+01 }, [8 x %Test] zeroinitializer }, align 16 +@test.b = local_unnamed_addr global { [4 x i32], { i32, i32, i32, i32 }, { i32, i32, [2 x i32] }, [4 x i32] } { [4 x i32] [i32 1, i32 2, i32 3, i32 4], { i32, i32, i32, i32 } { i32 5, i32 6, i32 7, i32 0 }, { i32, i32, [2 x i32] } { i32 8, i32 9, [2 x i32] zeroinitializer }, [4 x i32] zeroinitializer }, align 16 +@test.link = local_unnamed_addr global [3 x %Connection] [%Connection { i64 1, [10 x i8] c"link1\00\00\00\00\00", i64 10 }, %Connection { i64 2, [10 x i8] c"link2\00\00\00\00\00", i64 20 }, %Connection { i64 3, [10 x i8] c"link3\00\00\00\00\00", i64 30 }], align 16 @.str = private unnamed_addr constant [4 x i8] c"\1F\C2\8B\00", align 1 @.str.7 = private unnamed_addr constant [32 x i8] c"*** Word \22%s\22 on line %d is not\00", align 1 -declare i32 @test_strcmp(ptr, ptr) #0 +declare i32 @test.strcmp(ptr, ptr) #0 -define i32 @test_test(ptr %0) #0 { +define i32 @test.test(ptr %0) #0 { entry: - %1 = call i32 @test_strcmp(ptr %0, ptr @.str) + %1 = call i32 @test.strcmp(ptr %0, ptr @.str) ret i32 %1 } -define i32 @test_trys(ptr %0, i32 %1) #0 { +define i32 @test.trys(ptr %0, i32 %1) #0 { entry: %asa = alloca i32, align 4 %val = alloca double, align 8 diff --git a/test/test_suite/clang/2002-04.c3t b/test/test_suite/clang/2002-04.c3t index d135417e6..84c600fa9 100644 --- a/test/test_suite/clang/2002-04.c3t +++ b/test/test_suite/clang/2002-04.c3t @@ -68,7 +68,7 @@ fn void test2(FooSt y) { /* #expect: test.ll -define i32 @test_main2() #0 { +define i32 @test.main2() #0 { entry: %switch = alloca i32, align 4 br label %loop.cond @@ -110,7 +110,7 @@ loop.exit: ; preds = %loop.cond ret i32 0 } -define double @test_test(i32 %0) #0 { +define double @test.test(i32 %0) #0 { entry: %student_t = alloca [30 x double], align 16 call void @llvm.memcpy.p0.p0.i32(ptr align 16 %student_t, ptr align 16 @.__const, i32 240, i1 false) @@ -120,7 +120,7 @@ entry: ret double %2 } -define void @test_loop() #0 { +define void @test.loop() #0 { entry: %result = alloca %St, align 4 %0 = call i64 @func_returning_struct() @@ -132,14 +132,14 @@ declare i32 @testF(ptr byval(%FooSt) align 8, float) #0 declare i32 @testE(i8 zeroext, i16 signext, i8 zeroext, i32, i32, float) #0 -define void @test_test3(ptr %0) #0 { +define void @test.test3(ptr %0) #0 { entry: %1 = getelementptr inbounds %FooSt, ptr %0, i32 0, i32 1 store i16 1, ptr %1, align 2 ret void } -define void @test_test2(ptr byval(%FooSt) align 8 %0) #0 { +define void @test.test2(ptr byval(%FooSt) align 8 %0) #0 { entry: %indirectarg = alloca %FooSt, align 8 %indirectarg1 = alloca %FooSt, align 8 @@ -158,7 +158,7 @@ entry: call void @llvm.memcpy.p0.p0.i32(ptr align 8 %indirectarg, ptr align 4 %0, i32 20, i1 false) %12 = call i32 @testF(ptr byval(%FooSt) align 8 %indirectarg, float 0x3FB99999A0000000) call void @llvm.memcpy.p0.p0.i32(ptr align 8 %indirectarg1, ptr align 4 %0, i32 20, i1 false) - call void @test_test2(ptr byval(%FooSt) align 8 %indirectarg1) - call void @test_test3(ptr %0) + call void @test.test2(ptr byval(%FooSt) align 8 %indirectarg1) + call void @test.test3(ptr %0) ret void } diff --git a/test/test_suite/clang/2002-07.c3t b/test/test_suite/clang/2002-07.c3t index 3ae3b30d3..256f4e27e 100644 --- a/test/test_suite/clang/2002-07.c3t +++ b/test/test_suite/clang/2002-07.c3t @@ -296,34 +296,34 @@ fn int strcmp(char *s1, char *s2) { /* #expect: foo.ll -@foo_data = local_unnamed_addr global ptr null, align 8 -@foo_listNode3 = global %List { i32 4, ptr null }, align 8 -@foo_listNode2 = global %List { i32 3, ptr @foo_listNode3 }, align 8 -@foo_listNode0 = local_unnamed_addr global %List { i32 1, ptr @foo_listNode1 }, align 8 -@foo_listNode1 = global %List { i32 2, ptr @foo_listNode2 }, align 8 -@foo_listArray = local_unnamed_addr global [10 x %List] zeroinitializer, align 16 -@foo_temp = protected unnamed_addr global ptr null, align 8 -@foo_remaining = protected unnamed_addr global i32 0, align 4 -@foo_ext = local_unnamed_addr global ptr null, align 8 -@foo_globalQuad = local_unnamed_addr global %Quad { i32 4, %SubStruct { i16 1, i16 2 }, ptr null, i8 3, i32 156 }, align 8 +@foo.data = local_unnamed_addr global ptr null, align 8 +@foo.listNode3 = global %List { i32 4, ptr null }, align 8 +@foo.listNode2 = global %List { i32 3, ptr @foo.listNode3 }, align 8 +@foo.listNode0 = local_unnamed_addr global %List { i32 1, ptr @foo.listNode1 }, align 8 +@foo.listNode1 = global %List { i32 2, ptr @foo.listNode2 }, align 8 +@foo.listArray = local_unnamed_addr global [10 x %List] zeroinitializer, align 16 +@foo.temp = protected unnamed_addr global ptr null, align 8 +@foo.remaining = protected unnamed_addr global i32 0, align 4 +@foo.ext = local_unnamed_addr global ptr null, align 8 +@foo.globalQuad = local_unnamed_addr global %Quad { i32 4, %SubStruct { i16 1, i16 2 }, ptr null, i8 3, i32 156 }, align 8 @"foo$foo" = internal unnamed_addr global i32 0, align 4 -define ptr @foo_passThroughList(ptr %0) #0 { +define ptr @foo.passThroughList(ptr %0) #0 { entry: ret ptr %0 } -define void @foo_foo() #0 { +define void @foo.foo() #0 { entry: %0 = load i32, ptr @"foo$foo", align 4 %add = add i32 %0, 1 store i32 %add, ptr @"foo$foo", align 4 %1 = call ptr @malloc(i32 12) - store ptr %1, ptr @foo_data, align 8 + store ptr %1, ptr @foo.data, align 8 ret void } -define void @foo_insertIntoListTail(ptr %0, i32 %1) #0 { +define void @foo.insertIntoListTail(ptr %0, i32 %1) #0 { entry: %l = alloca ptr, align 8 store ptr %0, ptr %l, align 8 @@ -357,7 +357,7 @@ loop.exit: ; preds = %loop.cond ret void } -define ptr @foo_findData(ptr %0, i32 %1) #0 { +define ptr @foo.findData(ptr %0, i32 %1) #0 { entry: %not = icmp eq ptr %0, null br i1 %not, label %if.then, label %if.exit @@ -377,23 +377,23 @@ if.then1: ; preds = %if.exit if.exit2: ; preds = %if.exit %4 = getelementptr inbounds %List, ptr %0, i32 0, i32 1 %5 = load ptr, ptr %4, align 8 - %6 = call ptr @foo_findData(ptr %5, i32 %1) + %6 = call ptr @foo.findData(ptr %5, i32 %1) ret ptr %6 } -define void @foo_doListStuff() #0 { +define void @foo.doListStuff() #0 { entry: %myList = alloca ptr, align 8 store ptr null, ptr %myList, align 8 - call void @foo_insertIntoListTail(ptr %myList, i32 100) - call void @foo_insertIntoListTail(ptr %myList, i32 12) - call void @foo_insertIntoListTail(ptr %myList, i32 42) - call void @foo_insertIntoListTail(ptr %myList, i32 1123) - call void @foo_insertIntoListTail(ptr %myList, i32 1213) + call void @foo.insertIntoListTail(ptr %myList, i32 100) + call void @foo.insertIntoListTail(ptr %myList, i32 12) + call void @foo.insertIntoListTail(ptr %myList, i32 42) + call void @foo.insertIntoListTail(ptr %myList, i32 1123) + call void @foo.insertIntoListTail(ptr %myList, i32 1213) %0 = load ptr, ptr %myList, align 8 - %1 = call ptr @foo_findData(ptr %0, i32 75) + %1 = call ptr @foo.findData(ptr %0, i32 75) %ptrbool = icmp ne ptr %1, null br i1 %ptrbool, label %if.then, label %if.exit @@ -403,7 +403,7 @@ if.then: ; preds = %entry if.exit: ; preds = %if.then, %entry %2 = load ptr, ptr %myList, align 8 - %3 = call ptr @foo_findData(ptr %2, i32 42) + %3 = call ptr @foo.findData(ptr %2, i32 42) %ptrbool1 = icmp ne ptr %3, null br i1 %ptrbool1, label %if.then2, label %if.exit3 @@ -413,7 +413,7 @@ if.then2: ; preds = %if.exit if.exit3: ; preds = %if.then2, %if.exit %4 = load ptr, ptr %myList, align 8 - %5 = call ptr @foo_findData(ptr %4, i32 700) + %5 = call ptr @foo.findData(ptr %4, i32 700) %ptrbool4 = icmp ne ptr %5, null br i1 %ptrbool4, label %if.then5, label %if.exit6 @@ -425,7 +425,7 @@ if.exit6: ; preds = %if.then5, %if.exit3 ret void } -define i32 @foo_floatcomptest(ptr %0, ptr %1, ptr %2, ptr %3) #0 { +define i32 @foo.floatcomptest(ptr %0, ptr %1, ptr %2, ptr %3) #0 { entry: %4 = load double, ptr %0, align 8 %5 = load double, ptr %1, align 8 @@ -445,7 +445,7 @@ or.phi: ; preds = %or.rhs, %entry } -define ptr @foo_memset_impl(ptr %0, i32 %1, i32 %2) #0 { +define ptr @foo.memset_impl(ptr %0, i32 %1, i32 %2) #0 { entry: %len = alloca i32, align 4 %dstp = alloca i64, align 8 @@ -478,26 +478,26 @@ loop.exit: ; preds = %loop.cond ret ptr %0 } -define internal ptr @foo_localmalloc(i32 %0) #0 { +define internal ptr @foo.localmalloc(i32 %0) #0 { entry: %blah = alloca ptr, align 8 store ptr null, ptr %blah, align 8 - %1 = load i32, ptr @foo_remaining, align 4 + %1 = load i32, ptr @foo.remaining, align 4 %gt = icmp sgt i32 %0, %1 br i1 %gt, label %if.then, label %if.exit if.then: ; preds = %entry %2 = call ptr @malloc(i32 32768) - store ptr %2, ptr @foo_temp, align 8 - store i32 32768, ptr @foo_remaining, align 4 - %3 = load ptr, ptr @foo_temp, align 8 + store ptr %2, ptr @foo.temp, align 8 + store i32 32768, ptr @foo.remaining, align 4 + %3 = load ptr, ptr @foo.temp, align 8 ret ptr %3 if.exit: ; preds = %entry ret ptr null } -define void @foo_testRetStruct(ptr noalias sret(%PBVTest) align 8 %0, float %1, double %2, i32 %3) #0 { +define void @foo.testRetStruct(ptr noalias sret(%PBVTest) align 8 %0, float %1, double %2, i32 %3) #0 { entry: %t = alloca %PBVTest, align 8 %4 = getelementptr inbounds %PBVTest, ptr %t, i32 0, i32 0 @@ -511,7 +511,7 @@ entry: ret void } -define double @foo_callRetStruct(float %0, double %1, i32 %2) #0 { +define double @foo.callRetStruct(float %0, double %1, i32 %2) #0 { entry: %t = alloca %PBVTest, align 8 call void @testRetStruct2(ptr sret(%PBVTest) align 8 %t) @@ -526,14 +526,14 @@ entry: } -define void @foo___bb_exit_func() #0 { +define void @foo.__bb_exit_func() #0 { entry: - %0 = load ptr, ptr @foo_ext, align 8 + %0 = load ptr, ptr @foo.ext, align 8 %ptrbool = icmp ne ptr %0, null br i1 %ptrbool, label %cond.lhs, label %cond.rhs cond.lhs: ; preds = %entry - %1 = load ptr, ptr @foo_ext, align 8 + %1 = load ptr, ptr @foo.ext, align 8 br label %cond.phi cond.rhs: ; preds = %entry @@ -545,13 +545,13 @@ cond.phi: ; preds = %cond.rhs, %cond.lhs ret void } -define i32 @foo_ptrFunc(ptr %0, i32 %1) #0 { +define i32 @foo.ptrFunc(ptr %0, i32 %1) #0 { entry: %2 = call i32 %0(i32 %1) ret i32 %2 } -define zeroext i8 @foo_ptrFunc2(ptr byval([30 x ptr]) align 8 %0, i32 %1) #0 { +define zeroext i8 @foo.ptrFunc2(ptr byval([30 x ptr]) align 8 %0, i32 %1) #0 { entry: %sisiext = sext i32 %1 to i64 %2 = getelementptr inbounds [30 x ptr], ptr %0, i64 0, i64 %sisiext @@ -561,7 +561,7 @@ entry: ret i8 %siuitrunc } -define zeroext i8 @foo_smallArgs(i8 zeroext %0, i8 zeroext %1, i8 zeroext %2, i8 zeroext %3) #0 { +define zeroext i8 @foo.smallArgs(i8 zeroext %0, i8 zeroext %1, i8 zeroext %2, i8 zeroext %3) #0 { entry: %4 = call i32 @someFuncA() %uisiext = zext i8 %0 to i32 @@ -575,7 +575,7 @@ entry: ret i8 %5 } -define internal i32 @foo_f0(ptr byval(%Quad) align 8 %0, i32 %1) #0 { +define internal i32 @foo.f0(ptr byval(%Quad) align 8 %0, i32 %1) #0 { entry: %r = alloca %Quad, align 8 %intbool = icmp ne i32 %1, 0 @@ -612,7 +612,7 @@ if.exit: ; preds = %if.then, %entry ret i32 %sub } -define i32 @foo_f1(ptr %0, i32 %1) #0 { +define i32 @foo.f1(ptr %0, i32 %1) #0 { entry: %r = alloca %Quad, align 8 %intbool = icmp ne i32 %1, 0 @@ -644,7 +644,7 @@ if.exit: ; preds = %if.then, %entry ret i32 %sub } -define i32 @foo_badFunc(float %0) #0 { +define i32 @foo.badFunc(float %0) #0 { entry: %result = alloca i32, align 4 %fpfpext = fpext float %0 to double @@ -660,7 +660,7 @@ if.exit: ; preds = %if.then, %entry ret i32 %1 } -define i32 @foo_func(i32 %0, i64 %1) #0 { +define i32 @foo.func(i32 %0, i64 %1) #0 { entry: %result = alloca i32, align 4 %c = alloca i8, align 1 @@ -676,7 +676,7 @@ entry: ret i32 %4 } -define signext i16 @foo_funFunc(i64 %0, i8 zeroext %1) #0 { +define signext i16 @foo.funFunc(i64 %0, i8 zeroext %1) #0 { entry: %uisiext = zext i8 %1 to i64 %add = add i64 %0, %uisiext @@ -684,12 +684,12 @@ entry: ret i16 %sisitrunc } -define i32 @foo_castTest(i32 %0) #0 { +define i32 @foo.castTest(i32 %0) #0 { entry: ret i32 %0 } -define double @foo_testAdd(double %0, float %1) #0 { +define double @foo.testAdd(double %0, float %1) #0 { entry: %fpfpext = fpext float %1 to double %fadd = fadd double %0, %fpfpext @@ -697,7 +697,7 @@ entry: ret double %fadd1 } -define i32 @foo_funcZ(i32 %0, i32 %1) #0 { +define i32 @foo.funcZ(i32 %0, i32 %1) #0 { entry: %i = alloca i32, align 4 %j = alloca i32, align 4 @@ -719,7 +719,7 @@ loop.body: ; preds = %loop.cond loop.exit: ; preds = %loop.cond %4 = load i32, ptr %j, align 4 %5 = load i32, ptr %i, align 4 - %6 = call i32 @foo_funcZ(i32 2, i32 %5) + %6 = call i32 @foo.funcZ(i32 2, i32 %5) %add1 = add i32 %4, %6 store i32 %add1, ptr %j, align 4 %7 = load i32, ptr %i, align 4 @@ -732,7 +732,7 @@ loop.exit: ; preds = %loop.cond ret i32 %mul4 } -define i32 @foo_sumArray(ptr %0, i32 %1) #0 { +define i32 @foo.sumArray(ptr %0, i32 %1) #0 { entry: %i = alloca i32, align 4 %result = alloca i32, align 4 @@ -763,7 +763,7 @@ loop.exit: ; preds = %loop.cond ret i32 %7 } -define i32 @foo_arrayParam(ptr %0) #0 { +define i32 @foo.arrayParam(ptr %0) #0 { entry: %ptroffset = getelementptr inbounds i32, ptr %0, i64 50 %1 = load i32, ptr %ptroffset, align 4 @@ -774,7 +774,7 @@ entry: ret i32 %2 } -define i32 @foo_arrayToSum() #0 { +define i32 @foo.arrayToSum() #0 { entry: %a = alloca [100 x i32], align 16 %i = alloca i32, align 4 @@ -813,7 +813,7 @@ entry: %i = alloca i32, align 4 %2 = call i32 @puts(ptr @.str.10) %sisitrunc = trunc i32 %0 to i16 - %3 = call i32 @foo_externFunc(i64 -1, ptr null, i16 signext %sisitrunc, i8 zeroext 2) + %3 = call i32 @foo.externFunc(i64 -1, ptr null, i16 signext %sisitrunc, i8 zeroext 2) store i32 0, ptr %i, align 4 br label %loop.cond @@ -835,7 +835,7 @@ loop.exit: ; preds = %loop.cond ret i32 0 } -define double @foo_mathFunc(double %0, double %1, double %2, double %3, double %4, double %5, double %6, double %7, double %8, double %9, double %10, double %11, double %12, double %13, double %14, double %15, double %16) #0 { +define double @foo.mathFunc(double %0, double %1, double %2, double %3, double %4, double %5, double %6, double %7, double %8, double %9, double %10, double %11, double %12, double %13, double %14, double %15, double %16) #0 { entry: %fadd = fadd double %0, %1 %fadd1 = fadd double %fadd, %2 @@ -856,7 +856,7 @@ entry: ret double %fadd15 } -define void @foo_strcpy(ptr %0, ptr %1) #0 { +define void @foo.strcpy(ptr %0, ptr %1) #0 { entry: %s1 = alloca ptr, align 8 %s2 = alloca ptr, align 8 @@ -883,7 +883,7 @@ loop.exit: ; preds = %loop.cond ret void } -define void @foo_strcat(ptr %0, ptr %1) #0 { +define void @foo.strcat(ptr %0, ptr %1) #0 { entry: %s1 = alloca ptr, align 8 %s2 = alloca ptr, align 8 @@ -927,7 +927,7 @@ loop.exit7: ; preds = %loop.cond2 ret void } -define i32 @foo_strcmp(ptr %0, ptr %1) #0 { +define i32 @foo.strcmp(ptr %0, ptr %1) #0 { entry: %s1 = alloca ptr, align 8 %s2 = alloca ptr, align 8 diff --git a/test/test_suite/compile_time/compile_time_access_subscript.c3t b/test/test_suite/compile_time/compile_time_access_subscript.c3t index d03136d7f..9ce9e5595 100644 --- a/test/test_suite/compile_time/compile_time_access_subscript.c3t +++ b/test/test_suite/compile_time/compile_time_access_subscript.c3t @@ -95,9 +95,9 @@ fn void main() %13 = getelementptr inbounds %Abc, ptr %literal, i32 0, i32 3 store float 0.000000e+00, ptr %13, align 4 %14 = insertvalue %variant undef, ptr %literal, 0 - %15 = insertvalue %variant %14, i64 ptrtoint (ptr @"ct$test_Abc" to i64), 1 + %15 = insertvalue %variant %14, i64 ptrtoint (ptr @"ct$test.Abc" to i64), 1 %16 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %15, ptr %16, align 16 - %17 = call i64 @std_io_printfn(ptr %retparam, ptr @.str, i64 2, ptr %varargslots, i64 1) + %17 = call i64 @std_io.printfn(ptr %retparam, ptr @.str, i64 2, ptr %varargslots, i64 1) ret void } diff --git a/test/test_suite/compile_time/compile_time_array.c3t b/test/test_suite/compile_time/compile_time_array.c3t index 412ce0b29..c108d0651 100644 --- a/test/test_suite/compile_time/compile_time_array.c3t +++ b/test/test_suite/compile_time/compile_time_array.c3t @@ -18,7 +18,7 @@ fn void test() @.str = private unnamed_addr constant [2 x i8] c"a\00", align 1 ; Function Attrs: nounwind -define void @test_test() #0 { +define void @test.test() #0 { entry: %x = alloca i32, align 4 %z = alloca %"char[]", align 8 diff --git a/test/test_suite/compile_time/compile_time_array_ref.c3t b/test/test_suite/compile_time/compile_time_array_ref.c3t index 2955ab0db..b6c5341ab 100644 --- a/test/test_suite/compile_time/compile_time_array_ref.c3t +++ b/test/test_suite/compile_time/compile_time_array_ref.c3t @@ -12,7 +12,7 @@ fn void test() /* #expect: foo.ll -@foo_stack = local_unnamed_addr global [8192 x i8] zeroinitializer, align 16 -@foo_x = local_unnamed_addr global ptr getelementptr (i8, ptr @foo_stack, i64 1000), align 8 +@foo.stack = local_unnamed_addr global [8192 x i8] zeroinitializer, align 16 +@foo.x = local_unnamed_addr global ptr getelementptr (i8, ptr @foo.stack, i64 1000), align 8 @"test$y" = internal unnamed_addr global [2 x i8] zeroinitializer, align 1 @"test$z" = internal unnamed_addr global ptr getelementptr inbounds ([2 x i8], ptr @"test$y", i64 0, i64 1), align 8 \ No newline at end of file diff --git a/test/test_suite/compile_time/compile_time_bitops.c3t b/test/test_suite/compile_time/compile_time_bitops.c3t index 92f924f2b..573a5aac9 100644 --- a/test/test_suite/compile_time/compile_time_bitops.c3t +++ b/test/test_suite/compile_time/compile_time_bitops.c3t @@ -10,9 +10,9 @@ int y3 = ~4; /* #expect: foo.ll -@foo_x1 = local_unnamed_addr global i32 6, align 4 -@foo_x2 = local_unnamed_addr global i32 6, align 4 -@foo_x3 = local_unnamed_addr global i32 0, align 4 -@foo_y1 = local_unnamed_addr global i32 16, align 4 -@foo_y2 = local_unnamed_addr global i32 1, align 4 -@foo_y3 = local_unnamed_addr global i32 -5, align 4 \ No newline at end of file +@foo.x1 = local_unnamed_addr global i32 6, align 4 +@foo.x2 = local_unnamed_addr global i32 6, align 4 +@foo.x3 = local_unnamed_addr global i32 0, align 4 +@foo.y1 = local_unnamed_addr global i32 16, align 4 +@foo.y2 = local_unnamed_addr global i32 1, align 4 +@foo.y3 = local_unnamed_addr global i32 -5, align 4 \ No newline at end of file diff --git a/test/test_suite/compile_time/compile_time_pointers.c3t b/test/test_suite/compile_time/compile_time_pointers.c3t index 6e115970b..c3621f8aa 100644 --- a/test/test_suite/compile_time/compile_time_pointers.c3t +++ b/test/test_suite/compile_time/compile_time_pointers.c3t @@ -23,13 +23,13 @@ fn void test() /* #expect: test.ll -@test_ABC = local_unnamed_addr constant i64 531, align 8 -@test_BAC = local_unnamed_addr constant ptr inttoptr (i64 143 to ptr), align 8 -@test_EXX = local_unnamed_addr constant ptr inttoptr (i64 155 to ptr), align 8 -@test_KEX = local_unnamed_addr constant i64 -12, align 8 -@test_CAB = local_unnamed_addr constant ptr inttoptr (i64 143 to ptr), align 8 -@test_ZAB = local_unnamed_addr constant i64 143, align 8 -@test_BOB = local_unnamed_addr constant ptr inttoptr (i64 12 to ptr), align 8 -@test_BAB = local_unnamed_addr constant ptr inttoptr (i64 20 to ptr), align 8 -@test_AO = local_unnamed_addr constant i64 2, align 8 -@test_abc = local_unnamed_addr global i32 123, align 4 \ No newline at end of file +@test.ABC = local_unnamed_addr constant i64 531, align 8 +@test.BAC = local_unnamed_addr constant ptr inttoptr (i64 143 to ptr), align 8 +@test.EXX = local_unnamed_addr constant ptr inttoptr (i64 155 to ptr), align 8 +@test.KEX = local_unnamed_addr constant i64 -12, align 8 +@test.CAB = local_unnamed_addr constant ptr inttoptr (i64 143 to ptr), align 8 +@test.ZAB = local_unnamed_addr constant i64 143, align 8 +@test.BOB = local_unnamed_addr constant ptr inttoptr (i64 12 to ptr), align 8 +@test.BAB = local_unnamed_addr constant ptr inttoptr (i64 20 to ptr), align 8 +@test.AO = local_unnamed_addr constant i64 2, align 8 +@test.abc = local_unnamed_addr global i32 123, align 4 \ No newline at end of file diff --git a/test/test_suite/compile_time/compile_time_ptr_ref.c3t b/test/test_suite/compile_time/compile_time_ptr_ref.c3t index e4fc87bf1..730c96eb3 100644 --- a/test/test_suite/compile_time/compile_time_ptr_ref.c3t +++ b/test/test_suite/compile_time/compile_time_ptr_ref.c3t @@ -13,10 +13,10 @@ int ptr = 0; %"int*[]" = type { ptr, i64 } -@.taddr = private global [5 x ptr] [ptr @test_ptr, ptr @test_ptr, ptr getelementptr inbounds (i32, ptr @test_ptr, i64 1), ptr getelementptr (i32, ptr @test_ptr, i64 -1), ptr getelementptr (i8, ptr @test_ptr, i64 -4)], align 8 -@test_blurp = local_unnamed_addr global %"int*[]" { ptr @.taddr, i64 5 }, align 8 -@test_c = local_unnamed_addr global ptr getelementptr (i8, ptr @test_ptr, i64 -4), align 8 -@test_c2 = local_unnamed_addr global ptr getelementptr (i8, ptr @test_ptr, i64 4), align 8 -@test_c3 = local_unnamed_addr global ptr getelementptr (i8, ptr @test_ptr, i64 4), align 8 -@test_ff = local_unnamed_addr global i64 ptrtoint (ptr @test_ptr to i64), align 8 -@test_ptr = global i32 0, align 4 \ No newline at end of file +@.taddr = private global [5 x ptr] [ptr @test.ptr, ptr @test.ptr, ptr getelementptr inbounds (i32, ptr @test.ptr, i64 1), ptr getelementptr (i32, ptr @test.ptr, i64 -1), ptr getelementptr (i8, ptr @test.ptr, i64 -4)], align 8 +@test.blurp = local_unnamed_addr global %"int*[]" { ptr @.taddr, i64 5 }, align 8 +@test.c = local_unnamed_addr global ptr getelementptr (i8, ptr @test.ptr, i64 -4), align 8 +@test.c2 = local_unnamed_addr global ptr getelementptr (i8, ptr @test.ptr, i64 4), align 8 +@test.c3 = local_unnamed_addr global ptr getelementptr (i8, ptr @test.ptr, i64 4), align 8 +@test.ff = local_unnamed_addr global i64 ptrtoint (ptr @test.ptr to i64), align 8 +@test.ptr = global i32 0, align 4 \ No newline at end of file diff --git a/test/test_suite/compile_time/ct_builtin_time_date.c3t b/test/test_suite/compile_time/ct_builtin_time_date.c3t index f7e10a8a5..b4a14a041 100644 --- a/test/test_suite/compile_time/ct_builtin_time_date.c3t +++ b/test/test_suite/compile_time/ct_builtin_time_date.c3t @@ -27,7 +27,7 @@ fn void main() /* #expect: test.ll -define void @test_test(i32 %0) #0 { +define void @test.test(i32 %0) #0 { entry: %retparam = alloca i64, align 8 %varargslots = alloca [1 x %variant], align 16 @@ -55,47 +55,47 @@ entry: %2 = insertvalue %variant %1, i64 ptrtoint (ptr @"ct$int" to i64), 1 %3 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %2, ptr %3, align 16 - %4 = call i64 @std_io_printfn(ptr %retparam, ptr @.str, i64 2, ptr %varargslots, i64 1) + %4 = call i64 @std_io.printfn(ptr %retparam, ptr @.str, i64 2, ptr %varargslots, i64 1) %gt = icmp sgt i32 %0, 0 br i1 %gt, label %if.then, label %if.exit if.then: ; preds = %entry %sub = sub i32 %0, 1 - call void @test_test(i32 %sub) + call void @test.test(i32 %sub) br label %if.exit if.exit: ; preds = %if.then, %entry store ptr @.str.1, ptr %x, align 8 - %5 = call ptr @std_io_stdout() + %5 = call ptr @std_io.stdout() store ptr %5, ptr %result, align 8 %6 = load ptr, ptr %x, align 8 - %7 = call i64 @std_io_File_printn(ptr %retparam1, ptr %result, ptr %6, i64 8) + %7 = call i64 @std_io.File_printn(ptr %retparam1, ptr %result, ptr %6, i64 8) store ptr @.str.2, ptr %x2, align 8 - %8 = call ptr @std_io_stdout() + %8 = call ptr @std_io.stdout() store ptr %8, ptr %result4, align 8 %9 = load ptr, ptr %x2, align 8 - %10 = call i64 @std_io_File_printn(ptr %retparam3, ptr %result4, ptr %9, i64 10) + %10 = call i64 @std_io.File_printn(ptr %retparam3, ptr %result4, ptr %9, i64 10) store i64 14, ptr %taddr7, align 8 %11 = insertvalue %variant undef, ptr %taddr7, 0 %12 = insertvalue %variant %11, i64 ptrtoint (ptr @"ct$long" to i64), 1 %13 = getelementptr inbounds [1 x %variant], ptr %varargslots6, i64 0, i64 0 store %variant %12, ptr %13, align 16 - %14 = call i64 @std_io_printfn(ptr %retparam5, ptr @.str.3, i64 2, ptr %varargslots6, i64 1) + %14 = call i64 @std_io.printfn(ptr %retparam5, ptr @.str.3, i64 2, ptr %varargslots6, i64 1) store i64 6, ptr %taddr10, align 8 %15 = insertvalue %variant undef, ptr %taddr10, 0 %16 = insertvalue %variant %15, i64 ptrtoint (ptr @"ct$long" to i64), 1 %17 = getelementptr inbounds [1 x %variant], ptr %varargslots9, i64 0, i64 0 store %variant %16, ptr %17, align 16 - %18 = call i64 @std_io_printfn(ptr %retparam8, ptr @.str.4, i64 2, ptr %varargslots9, i64 1) + %18 = call i64 @std_io.printfn(ptr %retparam8, ptr @.str.4, i64 2, ptr %varargslots9, i64 1) store ptr @.str.5, ptr %x11, align 8 - %19 = call ptr @std_io_stdout() + %19 = call ptr @std_io.stdout() store ptr %19, ptr %result13, align 8 %20 = load ptr, ptr %x11, align 8 - %21 = call i64 @std_io_File_printn(ptr %retparam12, ptr %result13, ptr %20, i64 23) + %21 = call i64 @std_io.File_printn(ptr %retparam12, ptr %result13, ptr %20, i64 23) store ptr @.str.6, ptr %x14, align 8 - %22 = call ptr @std_io_stdout() + %22 = call ptr @std_io.stdout() store ptr %22, ptr %result16, align 8 %23 = load ptr, ptr %x14, align 8 - %24 = call i64 @std_io_File_printn(ptr %retparam15, ptr %result16, ptr %23, i64 4) + %24 = call i64 @std_io.File_printn(ptr %retparam15, ptr %result16, ptr %23, i64 4) ret void } \ No newline at end of file diff --git a/test/test_suite/compile_time/ct_eval.c3t b/test/test_suite/compile_time/ct_eval.c3t index b874f45d1..e9fea6cb2 100644 --- a/test/test_suite/compile_time/ct_eval.c3t +++ b/test/test_suite/compile_time/ct_eval.c3t @@ -11,7 +11,7 @@ fn void main() } /* #expect: test.ll -define void @test_main() #0 { +define void @test.main() #0 { entry: %abc = alloca i32, align 4 store i32 20, ptr %abc, align 4 diff --git a/test/test_suite/compile_time/ct_for.c3t b/test/test_suite/compile_time/ct_for.c3t index 34d6b921b..d7792222c 100644 --- a/test/test_suite/compile_time/ct_for.c3t +++ b/test/test_suite/compile_time/ct_for.c3t @@ -19,7 +19,7 @@ fn void main() /* #expect: test.ll -define void @test_main() #0 { +define void @test.main() #0 { entry: call void (ptr, ...) @printf(ptr @.str, i32 0) call void (ptr, ...) @printf(ptr @.str.1, i32 1) diff --git a/test/test_suite/compile_time/ct_foreach.c3t b/test/test_suite/compile_time/ct_foreach.c3t index 752a86234..71649bb19 100644 --- a/test/test_suite/compile_time/ct_foreach.c3t +++ b/test/test_suite/compile_time/ct_foreach.c3t @@ -28,7 +28,7 @@ fn void main() } /* #expect: test.ll -define void @test_main() #0 { +define void @test.main() #0 { entry: %z = alloca i32, align 4 %z1 = alloca ptr, align 8 diff --git a/test/test_suite/compile_time/ct_funcptr.c3t b/test/test_suite/compile_time/ct_funcptr.c3t index 13e82add8..d8df3cab9 100644 --- a/test/test_suite/compile_time/ct_funcptr.c3t +++ b/test/test_suite/compile_time/ct_funcptr.c3t @@ -16,19 +16,19 @@ fn void main() /* #expect: test.ll -define void @test_test(i32 %0) #0 { +define void @test.test(i32 %0) #0 { entry: %ptr = alloca ptr, align 8 %retparam = alloca i64, align 8 %varargslots = alloca [1 x %variant], align 16 %taddr = alloca i32, align 4 - store ptr @test_test, ptr %ptr, align 8 + store ptr @test.test, ptr %ptr, align 8 store i32 %0, ptr %taddr, align 4 %1 = insertvalue %variant undef, ptr %taddr, 0 %2 = insertvalue %variant %1, i64 ptrtoint (ptr @"ct$int" to i64), 1 %3 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %2, ptr %3, align 16 - %4 = call i64 @std_io_printfn(ptr %retparam, ptr @.str, i64 2, ptr %varargslots, i64 1) + %4 = call i64 @std_io.printfn(ptr %retparam, ptr @.str, i64 2, ptr %varargslots, i64 1) %gt = icmp sgt i32 %0, 0 br i1 %gt, label %if.then, label %if.exit diff --git a/test/test_suite/compile_time/ct_if.c3t b/test/test_suite/compile_time/ct_if.c3t index 296572c9a..4432be030 100644 --- a/test/test_suite/compile_time/ct_if.c3t +++ b/test/test_suite/compile_time/ct_if.c3t @@ -58,8 +58,8 @@ $endif; // #expect: ct_if.ll -@ct_if_d = local_unnamed_addr global i32 5, align 4 -@ct_if_c = local_unnamed_addr global i32 5, align 4 -@ct_if_b = local_unnamed_addr global i32 4, align 4 -@ct_if_a = local_unnamed_addr global i32 3, align 4 -@ct_if_x = local_unnamed_addr global i32 1, align 4 \ No newline at end of file +@ct_if.d = local_unnamed_addr global i32 5, align 4 +@ct_if.c = local_unnamed_addr global i32 5, align 4 +@ct_if.b = local_unnamed_addr global i32 4, align 4 +@ct_if.a = local_unnamed_addr global i32 3, align 4 +@ct_if.x = local_unnamed_addr global i32 1, align 4 \ No newline at end of file diff --git a/test/test_suite/compile_time/ct_memberof.c3t b/test/test_suite/compile_time/ct_memberof.c3t index 770ad51dc..84a193796 100644 --- a/test/test_suite/compile_time/ct_memberof.c3t +++ b/test/test_suite/compile_time/ct_memberof.c3t @@ -101,7 +101,7 @@ fn void main() /* #expect: test.ll -define void @test_hello(i32 %0, double %1, i64 %2, i64 %3, ptr %4, i64 %5) #0 { +define void @test.hello(i32 %0, double %1, i64 %2, i64 %3, ptr %4, i64 %5) #0 { entry: %d = alloca [4 x i32], align 8 %args = alloca %"variant[]", align 8 @@ -115,7 +115,7 @@ entry: } ; Function Attrs: nounwind -define void @test_test(i32 %0) #0 { +define void @test.test(i32 %0) #0 { entry: %x = alloca ptr, align 8 %retparam = alloca i64, align 8 @@ -188,46 +188,46 @@ entry: %taddr64 = alloca ptr, align 8 %taddr65 = alloca ptr, align 8 store ptr @.str, ptr %x, align 8 - %1 = call ptr @std_io_stdout() + %1 = call ptr @std_io.stdout() store ptr %1, ptr %result, align 8 %2 = load ptr, ptr %x, align 8 - %3 = call i64 @std_io_File_printn(ptr %retparam, ptr %result, ptr %2, i64 3) + %3 = call i64 @std_io.File_printn(ptr %retparam, ptr %result, ptr %2, i64 3) store ptr @.str.10, ptr %x1, align 8 - %4 = call ptr @std_io_stdout() + %4 = call ptr @std_io.stdout() store ptr %4, ptr %result3, align 8 %5 = load ptr, ptr %x1, align 8 - %6 = call i64 @std_io_File_printn(ptr %retparam2, ptr %result3, ptr %5, i64 3) + %6 = call i64 @std_io.File_printn(ptr %retparam2, ptr %result3, ptr %5, i64 3) store ptr @.str.11, ptr %x4, align 8 - %7 = call ptr @std_io_stdout() + %7 = call ptr @std_io.stdout() store ptr %7, ptr %result6, align 8 %8 = load ptr, ptr %x4, align 8 - %9 = call i64 @std_io_File_printn(ptr %retparam5, ptr %result6, ptr %8, i64 6) + %9 = call i64 @std_io.File_printn(ptr %retparam5, ptr %result6, ptr %8, i64 6) store ptr @.str.12, ptr %x7, align 8 - %10 = call ptr @std_io_stdout() + %10 = call ptr @std_io.stdout() store ptr %10, ptr %result9, align 8 %11 = load ptr, ptr %x7, align 8 - %12 = call i64 @std_io_File_printn(ptr %retparam8, ptr %result9, ptr %11, i64 6) + %12 = call i64 @std_io.File_printn(ptr %retparam8, ptr %result9, ptr %11, i64 6) store ptr @.str.13, ptr %x10, align 8 - %13 = call ptr @std_io_stdout() + %13 = call ptr @std_io.stdout() store ptr %13, ptr %result12, align 8 %14 = load ptr, ptr %x10, align 8 - %15 = call i64 @std_io_File_printn(ptr %retparam11, ptr %result12, ptr %14, i64 9) + %15 = call i64 @std_io.File_printn(ptr %retparam11, ptr %result12, ptr %14, i64 9) store ptr @.str.14, ptr %x13, align 8 - %16 = call ptr @std_io_stdout() + %16 = call ptr @std_io.stdout() store ptr %16, ptr %result15, align 8 %17 = load ptr, ptr %x13, align 8 - %18 = call i64 @std_io_File_printn(ptr %retparam14, ptr %result15, ptr %17, i64 4) + %18 = call i64 @std_io.File_printn(ptr %retparam14, ptr %result15, ptr %17, i64 4) store ptr @.str.15, ptr %x16, align 8 - %19 = call ptr @std_io_stdout() + %19 = call ptr @std_io.stdout() store ptr %19, ptr %result18, align 8 %20 = load ptr, ptr %x16, align 8 - %21 = call i64 @std_io_File_printn(ptr %retparam17, ptr %result18, ptr %20, i64 3) + %21 = call i64 @std_io.File_printn(ptr %retparam17, ptr %result18, ptr %20, i64 3) store ptr @.str.17, ptr %taddr, align 8 %22 = insertvalue %variant undef, ptr %taddr, 0 %23 = insertvalue %variant %22, i64 ptrtoint (ptr @"ct$p$a3$char" to i64), 1 %24 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %23, ptr %24, align 16 - %25 = call i64 @std_io_printfn(ptr %retparam19, ptr @.str.16, i64 8, ptr %varargslots, i64 1) + %25 = call i64 @std_io.printfn(ptr %retparam19, ptr @.str.16, i64 8, ptr %varargslots, i64 1) store ptr @.str.19, ptr %taddr22, align 8 %26 = insertvalue %variant undef, ptr %taddr22, 0 %27 = insertvalue %variant %26, i64 ptrtoint (ptr @"ct$p$a1$char" to i64), 1 @@ -238,7 +238,7 @@ entry: %30 = insertvalue %variant %29, i64 ptrtoint (ptr @"ct$p$a3$char" to i64), 1 %31 = getelementptr inbounds [2 x %variant], ptr %varargslots21, i64 0, i64 1 store %variant %30, ptr %31, align 16 - %32 = call i64 @std_io_printfn(ptr %retparam20, ptr @.str.18, i64 6, ptr %varargslots21, i64 2) + %32 = call i64 @std_io.printfn(ptr %retparam20, ptr @.str.18, i64 6, ptr %varargslots21, i64 2) store ptr @.str.22, ptr %taddr26, align 8 %33 = insertvalue %variant undef, ptr %taddr26, 0 %34 = insertvalue %variant %33, i64 ptrtoint (ptr @"ct$p$a4$char" to i64), 1 @@ -249,7 +249,7 @@ entry: %37 = insertvalue %variant %36, i64 ptrtoint (ptr @"ct$p$a4$char" to i64), 1 %38 = getelementptr inbounds [2 x %variant], ptr %varargslots25, i64 0, i64 1 store %variant %37, ptr %38, align 16 - %39 = call i64 @std_io_printfn(ptr %retparam24, ptr @.str.21, i64 6, ptr %varargslots25, i64 2) + %39 = call i64 @std_io.printfn(ptr %retparam24, ptr @.str.21, i64 6, ptr %varargslots25, i64 2) store ptr @.str.25, ptr %taddr30, align 8 %40 = insertvalue %variant undef, ptr %taddr30, 0 %41 = insertvalue %variant %40, i64 ptrtoint (ptr @"ct$p$a0$char" to i64), 1 @@ -260,7 +260,7 @@ entry: %44 = insertvalue %variant %43, i64 ptrtoint (ptr @"ct$p$a5$char" to i64), 1 %45 = getelementptr inbounds [2 x %variant], ptr %varargslots29, i64 0, i64 1 store %variant %44, ptr %45, align 16 - %46 = call i64 @std_io_printfn(ptr %retparam28, ptr @.str.24, i64 6, ptr %varargslots29, i64 2) + %46 = call i64 @std_io.printfn(ptr %retparam28, ptr @.str.24, i64 6, ptr %varargslots29, i64 2) store ptr @.str.28, ptr %taddr34, align 8 %47 = insertvalue %variant undef, ptr %taddr34, 0 %48 = insertvalue %variant %47, i64 ptrtoint (ptr @"ct$p$a1$char" to i64), 1 @@ -271,13 +271,13 @@ entry: %51 = insertvalue %variant %50, i64 ptrtoint (ptr @"ct$p$a6$char" to i64), 1 %52 = getelementptr inbounds [2 x %variant], ptr %varargslots33, i64 0, i64 1 store %variant %51, ptr %52, align 16 - %53 = call i64 @std_io_printfn(ptr %retparam32, ptr @.str.27, i64 6, ptr %varargslots33, i64 2) + %53 = call i64 @std_io.printfn(ptr %retparam32, ptr @.str.27, i64 6, ptr %varargslots33, i64 2) store ptr @.str.31, ptr %taddr38, align 8 %54 = insertvalue %variant undef, ptr %taddr38, 0 %55 = insertvalue %variant %54, i64 ptrtoint (ptr @"ct$p$a3$char" to i64), 1 %56 = getelementptr inbounds [1 x %variant], ptr %varargslots37, i64 0, i64 0 store %variant %55, ptr %56, align 16 - %57 = call i64 @std_io_printfn(ptr %retparam36, ptr @.str.30, i64 8, ptr %varargslots37, i64 1) + %57 = call i64 @std_io.printfn(ptr %retparam36, ptr @.str.30, i64 8, ptr %varargslots37, i64 1) store ptr @.str.33, ptr %taddr41, align 8 %58 = insertvalue %variant undef, ptr %taddr41, 0 %59 = insertvalue %variant %58, i64 ptrtoint (ptr @"ct$p$a1$char" to i64), 1 @@ -288,7 +288,7 @@ entry: %62 = insertvalue %variant %61, i64 ptrtoint (ptr @"ct$p$a4$char" to i64), 1 %63 = getelementptr inbounds [2 x %variant], ptr %varargslots40, i64 0, i64 1 store %variant %62, ptr %63, align 16 - %64 = call i64 @std_io_printfn(ptr %retparam39, ptr @.str.32, i64 6, ptr %varargslots40, i64 2) + %64 = call i64 @std_io.printfn(ptr %retparam39, ptr @.str.32, i64 6, ptr %varargslots40, i64 2) store ptr @.str.36, ptr %taddr45, align 8 %65 = insertvalue %variant undef, ptr %taddr45, 0 %66 = insertvalue %variant %65, i64 ptrtoint (ptr @"ct$p$a1$char" to i64), 1 @@ -299,7 +299,7 @@ entry: %69 = insertvalue %variant %68, i64 ptrtoint (ptr @"ct$p$a5$char" to i64), 1 %70 = getelementptr inbounds [2 x %variant], ptr %varargslots44, i64 0, i64 1 store %variant %69, ptr %70, align 16 - %71 = call i64 @std_io_printfn(ptr %retparam43, ptr @.str.35, i64 6, ptr %varargslots44, i64 2) + %71 = call i64 @std_io.printfn(ptr %retparam43, ptr @.str.35, i64 6, ptr %varargslots44, i64 2) store ptr @.str.39, ptr %taddr49, align 8 %72 = insertvalue %variant undef, ptr %taddr49, 0 %73 = insertvalue %variant %72, i64 ptrtoint (ptr @"ct$p$a0$char" to i64), 1 @@ -310,7 +310,7 @@ entry: %76 = insertvalue %variant %75, i64 ptrtoint (ptr @"ct$p$a5$char" to i64), 1 %77 = getelementptr inbounds [2 x %variant], ptr %varargslots48, i64 0, i64 1 store %variant %76, ptr %77, align 16 - %78 = call i64 @std_io_printfn(ptr %retparam47, ptr @.str.38, i64 6, ptr %varargslots48, i64 2) + %78 = call i64 @std_io.printfn(ptr %retparam47, ptr @.str.38, i64 6, ptr %varargslots48, i64 2) store ptr @.str.42, ptr %taddr53, align 8 %79 = insertvalue %variant undef, ptr %taddr53, 0 %80 = insertvalue %variant %79, i64 ptrtoint (ptr @"ct$p$a3$char" to i64), 1 @@ -321,13 +321,13 @@ entry: %83 = insertvalue %variant %82, i64 ptrtoint (ptr @"ct$p$a3$char" to i64), 1 %84 = getelementptr inbounds [2 x %variant], ptr %varargslots52, i64 0, i64 1 store %variant %83, ptr %84, align 16 - %85 = call i64 @std_io_printfn(ptr %retparam51, ptr @.str.41, i64 6, ptr %varargslots52, i64 2) + %85 = call i64 @std_io.printfn(ptr %retparam51, ptr @.str.41, i64 6, ptr %varargslots52, i64 2) store ptr @.str.45, ptr %taddr57, align 8 %86 = insertvalue %variant undef, ptr %taddr57, 0 %87 = insertvalue %variant %86, i64 ptrtoint (ptr @"ct$p$a4$char" to i64), 1 %88 = getelementptr inbounds [1 x %variant], ptr %varargslots56, i64 0, i64 0 store %variant %87, ptr %88, align 16 - %89 = call i64 @std_io_printfn(ptr %retparam55, ptr @.str.44, i64 8, ptr %varargslots56, i64 1) + %89 = call i64 @std_io.printfn(ptr %retparam55, ptr @.str.44, i64 8, ptr %varargslots56, i64 1) store ptr @.str.47, ptr %taddr60, align 8 %90 = insertvalue %variant undef, ptr %taddr60, 0 %91 = insertvalue %variant %90, i64 ptrtoint (ptr @"ct$p$a1$char" to i64), 1 @@ -338,7 +338,7 @@ entry: %94 = insertvalue %variant %93, i64 ptrtoint (ptr @"ct$p$a3$char" to i64), 1 %95 = getelementptr inbounds [2 x %variant], ptr %varargslots59, i64 0, i64 1 store %variant %94, ptr %95, align 16 - %96 = call i64 @std_io_printfn(ptr %retparam58, ptr @.str.46, i64 6, ptr %varargslots59, i64 2) + %96 = call i64 @std_io.printfn(ptr %retparam58, ptr @.str.46, i64 6, ptr %varargslots59, i64 2) store ptr @.str.50, ptr %taddr64, align 8 %97 = insertvalue %variant undef, ptr %taddr64, 0 %98 = insertvalue %variant %97, i64 ptrtoint (ptr @"ct$p$a1$char" to i64), 1 @@ -349,12 +349,12 @@ entry: %101 = insertvalue %variant %100, i64 ptrtoint (ptr @"ct$p$a5$char" to i64), 1 %102 = getelementptr inbounds [2 x %variant], ptr %varargslots63, i64 0, i64 1 store %variant %101, ptr %102, align 16 - %103 = call i64 @std_io_printfn(ptr %retparam62, ptr @.str.49, i64 6, ptr %varargslots63, i64 2) + %103 = call i64 @std_io.printfn(ptr %retparam62, ptr @.str.49, i64 6, ptr %varargslots63, i64 2) ret void } ; Function Attrs: nounwind -define void @test_main() #0 { +define void @test.main() #0 { entry: %retparam = alloca i64, align 8 %varargslots = alloca [1 x %variant], align 16 @@ -402,13 +402,13 @@ entry: %1 = insertvalue %variant %0, i64 ptrtoint (ptr @"ct$long" to i64), 1 %2 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %1, ptr %2, align 16 - %3 = call i64 @std_io_printfn(ptr %retparam, ptr @.str.52, i64 7, ptr %varargslots, i64 1) + %3 = call i64 @std_io.printfn(ptr %retparam, ptr @.str.52, i64 7, ptr %varargslots, i64 1) store i64 1, ptr %taddr3, align 8 %4 = insertvalue %variant undef, ptr %taddr3, 0 %5 = insertvalue %variant %4, i64 ptrtoint (ptr @"ct$long" to i64), 1 %6 = getelementptr inbounds [1 x %variant], ptr %varargslots2, i64 0, i64 0 store %variant %5, ptr %6, align 16 - %7 = call i64 @std_io_printfn(ptr %retparam1, ptr @.str.53, i64 7, ptr %varargslots2, i64 1) + %7 = call i64 @std_io.printfn(ptr %retparam1, ptr @.str.53, i64 7, ptr %varargslots2, i64 1) store i64 0, ptr %taddr6, align 8 %8 = insertvalue %variant undef, ptr %taddr6, 0 %9 = insertvalue %variant %8, i64 ptrtoint (ptr @"ct$ulong" to i64), 1 @@ -419,7 +419,7 @@ entry: %12 = insertvalue %variant %11, i64 ptrtoint (ptr @"ct$ulong" to i64), 1 %13 = getelementptr inbounds [2 x %variant], ptr %varargslots5, i64 0, i64 1 store %variant %12, ptr %13, align 16 - %14 = call i64 @std_io_printfn(ptr %retparam4, ptr @.str.54, i64 8, ptr %varargslots5, i64 2) + %14 = call i64 @std_io.printfn(ptr %retparam4, ptr @.str.54, i64 8, ptr %varargslots5, i64 2) store i64 2, ptr %taddr10, align 8 %15 = insertvalue %variant undef, ptr %taddr10, 0 %16 = insertvalue %variant %15, i64 ptrtoint (ptr @"ct$ulong" to i64), 1 @@ -430,7 +430,7 @@ entry: %19 = insertvalue %variant %18, i64 ptrtoint (ptr @"ct$ulong" to i64), 1 %20 = getelementptr inbounds [2 x %variant], ptr %varargslots9, i64 0, i64 1 store %variant %19, ptr %20, align 16 - %21 = call i64 @std_io_printfn(ptr %retparam8, ptr @.str.55, i64 8, ptr %varargslots9, i64 2) + %21 = call i64 @std_io.printfn(ptr %retparam8, ptr @.str.55, i64 8, ptr %varargslots9, i64 2) store i64 4, ptr %taddr14, align 8 %22 = insertvalue %variant undef, ptr %taddr14, 0 %23 = insertvalue %variant %22, i64 ptrtoint (ptr @"ct$ulong" to i64), 1 @@ -441,7 +441,7 @@ entry: %26 = insertvalue %variant %25, i64 ptrtoint (ptr @"ct$ulong" to i64), 1 %27 = getelementptr inbounds [2 x %variant], ptr %varargslots13, i64 0, i64 1 store %variant %26, ptr %27, align 16 - %28 = call i64 @std_io_printfn(ptr %retparam12, ptr @.str.56, i64 8, ptr %varargslots13, i64 2) + %28 = call i64 @std_io.printfn(ptr %retparam12, ptr @.str.56, i64 8, ptr %varargslots13, i64 2) store i64 4, ptr %taddr18, align 8 %29 = insertvalue %variant undef, ptr %taddr18, 0 %30 = insertvalue %variant %29, i64 ptrtoint (ptr @"ct$ulong" to i64), 1 @@ -452,7 +452,7 @@ entry: %33 = insertvalue %variant %32, i64 ptrtoint (ptr @"ct$ulong" to i64), 1 %34 = getelementptr inbounds [2 x %variant], ptr %varargslots17, i64 0, i64 1 store %variant %33, ptr %34, align 16 - %35 = call i64 @std_io_printfn(ptr %retparam16, ptr @.str.57, i64 8, ptr %varargslots17, i64 2) + %35 = call i64 @std_io.printfn(ptr %retparam16, ptr @.str.57, i64 8, ptr %varargslots17, i64 2) store i64 4, ptr %taddr22, align 8 %36 = insertvalue %variant undef, ptr %taddr22, 0 %37 = insertvalue %variant %36, i64 ptrtoint (ptr @"ct$ulong" to i64), 1 @@ -463,7 +463,7 @@ entry: %40 = insertvalue %variant %39, i64 ptrtoint (ptr @"ct$ulong" to i64), 1 %41 = getelementptr inbounds [2 x %variant], ptr %varargslots21, i64 0, i64 1 store %variant %40, ptr %41, align 16 - %42 = call i64 @std_io_printfn(ptr %retparam20, ptr @.str.58, i64 9, ptr %varargslots21, i64 2) + %42 = call i64 @std_io.printfn(ptr %retparam20, ptr @.str.58, i64 9, ptr %varargslots21, i64 2) store i64 5, ptr %taddr26, align 8 %43 = insertvalue %variant undef, ptr %taddr26, 0 %44 = insertvalue %variant %43, i64 ptrtoint (ptr @"ct$ulong" to i64), 1 @@ -474,7 +474,7 @@ entry: %47 = insertvalue %variant %46, i64 ptrtoint (ptr @"ct$ulong" to i64), 1 %48 = getelementptr inbounds [2 x %variant], ptr %varargslots25, i64 0, i64 1 store %variant %47, ptr %48, align 16 - %49 = call i64 @std_io_printfn(ptr %retparam24, ptr @.str.59, i64 9, ptr %varargslots25, i64 2) + %49 = call i64 @std_io.printfn(ptr %retparam24, ptr @.str.59, i64 9, ptr %varargslots25, i64 2) store i64 8, ptr %taddr30, align 8 %50 = insertvalue %variant undef, ptr %taddr30, 0 %51 = insertvalue %variant %50, i64 ptrtoint (ptr @"ct$ulong" to i64), 1 @@ -485,13 +485,13 @@ entry: %54 = insertvalue %variant %53, i64 ptrtoint (ptr @"ct$ulong" to i64), 1 %55 = getelementptr inbounds [2 x %variant], ptr %varargslots29, i64 0, i64 1 store %variant %54, ptr %55, align 16 - %56 = call i64 @std_io_printfn(ptr %retparam28, ptr @.str.60, i64 10, ptr %varargslots29, i64 2) + %56 = call i64 @std_io.printfn(ptr %retparam28, ptr @.str.60, i64 10, ptr %varargslots29, i64 2) store i64 4, ptr %taddr34, align 8 %57 = insertvalue %variant undef, ptr %taddr34, 0 %58 = insertvalue %variant %57, i64 ptrtoint (ptr @"ct$ulong" to i64), 1 %59 = getelementptr inbounds [1 x %variant], ptr %varargslots33, i64 0, i64 0 store %variant %58, ptr %59, align 16 - %60 = call i64 @std_io_printfn(ptr %retparam32, ptr @.str.61, i64 7, ptr %varargslots33, i64 1) + %60 = call i64 @std_io.printfn(ptr %retparam32, ptr @.str.61, i64 7, ptr %varargslots33, i64 1) store i64 8, ptr %taddr37, align 8 %61 = insertvalue %variant undef, ptr %taddr37, 0 %62 = insertvalue %variant %61, i64 ptrtoint (ptr @"ct$ulong" to i64), 1 @@ -502,7 +502,7 @@ entry: %65 = insertvalue %variant %64, i64 ptrtoint (ptr @"ct$ulong" to i64), 1 %66 = getelementptr inbounds [2 x %variant], ptr %varargslots36, i64 0, i64 1 store %variant %65, ptr %66, align 16 - %67 = call i64 @std_io_printfn(ptr %retparam35, ptr @.str.62, i64 10, ptr %varargslots36, i64 2) - call void @test_test(i32 10) + %67 = call i64 @std_io.printfn(ptr %retparam35, ptr @.str.62, i64 10, ptr %varargslots36, i64 2) + call void @test.test(i32 10) ret void } \ No newline at end of file diff --git a/test/test_suite/compile_time/ct_switch.c3t b/test/test_suite/compile_time/ct_switch.c3t index 9a832eb98..cdb8032a2 100644 --- a/test/test_suite/compile_time/ct_switch.c3t +++ b/test/test_suite/compile_time/ct_switch.c3t @@ -54,7 +54,7 @@ fn void main() declare void @printf(ptr, ...) #0 ; Function Attrs: nounwind -define void @test_main() #0 { +define void @test.main() #0 { entry: call void (ptr, ...) @printf(ptr @.str, ptr @.str.1) call void (ptr, ...) @printf(ptr @.str.2, ptr @.str.3) diff --git a/test/test_suite/compile_time/ct_switch_top_level.c3t b/test/test_suite/compile_time/ct_switch_top_level.c3t index 63c79fb90..a16e494bc 100644 --- a/test/test_suite/compile_time/ct_switch_top_level.c3t +++ b/test/test_suite/compile_time/ct_switch_top_level.c3t @@ -36,7 +36,7 @@ source_filename = "test" target datalayout = "e-m:o-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-apple-darwin" -@test_oeoekgokege = local_unnamed_addr global i32 343432, align 4 +@test.oeoekgokege = local_unnamed_addr global i32 343432, align 4 @.str = private unnamed_addr constant [7 x i8] c"Hello\0A\00", align 1 @.str.1 = private unnamed_addr constant [7 x i8] c"Hello\0A\00", align 1 diff --git a/test/test_suite/compile_time/ct_switch_type_check.c3t b/test/test_suite/compile_time/ct_switch_type_check.c3t index 69a492928..740caf557 100644 --- a/test/test_suite/compile_time/ct_switch_type_check.c3t +++ b/test/test_suite/compile_time/ct_switch_type_check.c3t @@ -37,7 +37,7 @@ fn void main() declare void @printf(ptr, ...) #0 ; Function Attrs: nounwind -define void @test_main() #0 { +define void @test.main() #0 { entry: call void (ptr, ...) @printf(ptr @.str, ptr @.str.1) call void (ptr, ...) @printf(ptr @.str.2, ptr @.str.3) diff --git a/test/test_suite/compile_time/stringify.c3t b/test/test_suite/compile_time/stringify.c3t index 81eb7f989..33ea827b7 100644 --- a/test/test_suite/compile_time/stringify.c3t +++ b/test/test_suite/compile_time/stringify.c3t @@ -42,7 +42,7 @@ fn void main() @.str.4 = private unnamed_addr constant [10 x i8] c"1 + 3 + a\00", align 1 @.str.5 = private unnamed_addr constant [15 x i8] c"Result was %d\0A\00", align 1 -define void @test_test() #0 { +define void @test.test() #0 { entry: %i = alloca i32, align 4 store i32 0, ptr %i, align 4 @@ -65,7 +65,7 @@ loop.exit: ; preds = %loop.cond ret void } -define void @test_main() #0 { +define void @test.main() #0 { entry: %t = alloca i64, align 8 %diff = alloca i64, align 8 @@ -76,7 +76,7 @@ entry: %diff2 = alloca i64, align 8 %0 = call i64 @clock() store i64 %0, ptr %t, align 8 - call void @test_test() + call void @test.test() %1 = call i64 @clock() %2 = load i64, ptr %t, align 8 %sub = sub i64 %1, %2 @@ -104,6 +104,6 @@ entry: define i32 @main(i32 %0, ptr %1) #0 { entry: - call void @test_main() + call void @test.main() ret i32 0 } diff --git a/test/test_suite/compile_time/ternary_folding.c3t b/test/test_suite/compile_time/ternary_folding.c3t index be61e6765..b53487ddb 100644 --- a/test/test_suite/compile_time/ternary_folding.c3t +++ b/test/test_suite/compile_time/ternary_folding.c3t @@ -13,11 +13,11 @@ fn int test2() { return 3; } /* #expect: ternary_folding.ll -@ternary_folding_foo = local_unnamed_addr global i32 1, align 4 -@ternary_folding_bar = local_unnamed_addr global double 2.000000e+00, align 8 -@ternary_folding_baz = local_unnamed_addr global i8 0, align 1 +@ternary_folding.foo = local_unnamed_addr global i32 1, align 4 +@ternary_folding.bar = local_unnamed_addr global double 2.000000e+00, align 8 +@ternary_folding.baz = local_unnamed_addr global i8 0, align 1 -define void @ternary_folding_test() #0 { +define void @ternary_folding.test() #0 { entry: %x = alloca i32, align 4 store i32 0, ptr %x, align 4 diff --git a/test/test_suite/compile_time/typed_ct_vars.c3t b/test/test_suite/compile_time/typed_ct_vars.c3t index 09965ce4e..5c2ea6438 100644 --- a/test/test_suite/compile_time/typed_ct_vars.c3t +++ b/test/test_suite/compile_time/typed_ct_vars.c3t @@ -16,7 +16,7 @@ fn void test() /* #expect: test.ll -define void @test_test() #0 { +define void @test.test() #0 { entry: %y = alloca %Foo, align 4 %z = alloca %Foo, align 4 diff --git a/test/test_suite/compile_time/untyped_conversions.c3t b/test/test_suite/compile_time/untyped_conversions.c3t index fd2d4858a..20d4a8a52 100644 --- a/test/test_suite/compile_time/untyped_conversions.c3t +++ b/test/test_suite/compile_time/untyped_conversions.c3t @@ -29,7 +29,7 @@ fn void main() %"int[]" = type { ptr, i64 } %variant = type { ptr, i64 } -@"ct$test_Foo" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 +@"ct$test.Foo" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 @.str = private unnamed_addr constant [9 x i8] c"%s %s %s\00", align 1 @"ct$int" = linkonce constant %.introspect { i8 2, i64 4, i64 0, i64 0, [0 x i64] zeroinitializer }, align 8 @"ct$a2$int" = linkonce constant %.introspect { i8 15, i64 8, i64 ptrtoint (ptr @"ct$int" to i64), i64 2, [0 x i64] zeroinitializer }, align 8 @@ -46,7 +46,7 @@ fn void main() @"ct$a1$a2$double" = linkonce constant %.introspect { i8 15, i64 16, i64 ptrtoint (ptr @"ct$a2$double" to i64), i64 1, [0 x i64] zeroinitializer }, align 8 ; Function Attrs: nounwind -define void @test_test(i64 %0, ptr %1, i64 %2, double %3) #0 { +define void @test.test(i64 %0, ptr %1, i64 %2, double %3) #0 { entry: %a = alloca [2 x i32], align 4 %b = alloca %"int[]", align 8 @@ -70,12 +70,12 @@ entry: %11 = insertvalue %variant %10, i64 ptrtoint (ptr @"ct$v2$int" to i64), 1 %12 = getelementptr inbounds [3 x %variant], ptr %varargslots, i64 0, i64 2 store %variant %11, ptr %12, align 16 - %13 = call i64 @std_io_printfn(ptr %retparam, ptr @.str, i64 8, ptr %varargslots, i64 3) + %13 = call i64 @std_io.printfn(ptr %retparam, ptr @.str, i64 8, ptr %varargslots, i64 3) ret void } ; Function Attrs: nounwind -define void @test_main() #0 { +define void @test.main() #0 { entry: %abc = alloca [1 x %Foo], align 4 %def = alloca %Foo, align 4 @@ -111,7 +111,7 @@ entry: %12 = insertvalue %variant %11, i64 ptrtoint (ptr @"ct$int" to i64), 1 %13 = getelementptr inbounds [4 x %variant], ptr %varargslots, i64 0, i64 3 store %variant %12, ptr %13, align 16 - %14 = call i64 @std_io_printfn(ptr %retparam, ptr @.str.4, i64 14, ptr %varargslots, i64 4) + %14 = call i64 @std_io.printfn(ptr %retparam, ptr @.str.4, i64 14, ptr %varargslots, i64 4) %15 = getelementptr inbounds [2 x i32], ptr %literal, i64 0, i64 0 store i32 1, ptr %15, align 4 %16 = getelementptr inbounds [2 x i32], ptr %literal, i64 0, i64 1 @@ -123,7 +123,7 @@ entry: store i32 4, ptr %19, align 4 store <2 x i32> , ptr %taddr, align 8 %20 = load double, ptr %taddr, align 8 - call void @test_test(i64 %17, ptr %literal1, i64 2, double %20) + call void @test.test(i64 %17, ptr %literal1, i64 2, double %20) %21 = getelementptr inbounds [2 x i32], ptr %literal2, i64 0, i64 0 store i32 2, ptr %21, align 4 %22 = getelementptr inbounds [2 x i32], ptr %literal2, i64 0, i64 1 @@ -135,6 +135,6 @@ entry: store i32 7, ptr %25, align 4 store <2 x i32> , ptr %taddr4, align 8 %26 = load double, ptr %taddr4, align 8 - call void @test_test(i64 %23, ptr %literal3, i64 2, double %26) + call void @test.test(i64 %23, ptr %literal3, i64 2, double %26) ret void } diff --git a/test/test_suite/compile_time_introspection/alignof.c3t b/test/test_suite/compile_time_introspection/alignof.c3t index c3f585a55..67931e9e9 100644 --- a/test/test_suite/compile_time_introspection/alignof.c3t +++ b/test/test_suite/compile_time_introspection/alignof.c3t @@ -52,14 +52,14 @@ int z0 = Foob.c.alignof; /* #expect: foo.ll -@foo_x = local_unnamed_addr global i64 16, align 8 -@foo_y = local_unnamed_addr global i16 8, align 2 -@foo_z = local_unnamed_addr global i32 4, align 4 -@foo_v = local_unnamed_addr global i32 4, align 4 -@foo_x1 = local_unnamed_addr global i32 8, align 4 -@foo_x2 = local_unnamed_addr global i32 8, align 4 -@foo_x3 = local_unnamed_addr global i32 1, align 4 -@foo_x9 = local_unnamed_addr global i32 4, align 4 -@foo_x10 = local_unnamed_addr global i32 4, align 4 -@foo_x11 = local_unnamed_addr global i32 4, align 4 -@foo_z0 = local_unnamed_addr global i32 8, align 4 +@foo.x = local_unnamed_addr global i64 16, align 8 +@foo.y = local_unnamed_addr global i16 8, align 2 +@foo.z = local_unnamed_addr global i32 4, align 4 +@foo.v = local_unnamed_addr global i32 4, align 4 +@foo.x1 = local_unnamed_addr global i32 8, align 4 +@foo.x2 = local_unnamed_addr global i32 8, align 4 +@foo.x3 = local_unnamed_addr global i32 1, align 4 +@foo.x9 = local_unnamed_addr global i32 4, align 4 +@foo.x10 = local_unnamed_addr global i32 4, align 4 +@foo.x11 = local_unnamed_addr global i32 4, align 4 +@foo.z0 = local_unnamed_addr global i32 8, align 4 diff --git a/test/test_suite/compile_time_introspection/defined.c3t b/test/test_suite/compile_time_introspection/defined.c3t index 8b3a5fe9e..452418a72 100644 --- a/test/test_suite/compile_time_introspection/defined.c3t +++ b/test/test_suite/compile_time_introspection/defined.c3t @@ -61,7 +61,7 @@ fn void main() /* #expect: mymodule.ll -define void @mymodule_main() #0 { +define void @mymodule.main() #0 { entry: %x = alloca i32, align 4 %y = alloca i32, align 4 diff --git a/test/test_suite/compile_time_introspection/defined_builtin.c3t b/test/test_suite/compile_time_introspection/defined_builtin.c3t index 582b62f50..c7dc9d835 100644 --- a/test/test_suite/compile_time_introspection/defined_builtin.c3t +++ b/test/test_suite/compile_time_introspection/defined_builtin.c3t @@ -8,7 +8,7 @@ fn void test() /* #expect: foo.ll -define void @foo_test() #0 { +define void @foo.test() #0 { entry: %a = alloca i8, align 1 %b = alloca i8, align 1 diff --git a/test/test_suite/compile_time_introspection/nameof.c3t b/test/test_suite/compile_time_introspection/nameof.c3t index eafd32cad..5246aa0e9 100644 --- a/test/test_suite/compile_time_introspection/nameof.c3t +++ b/test/test_suite/compile_time_introspection/nameof.c3t @@ -43,9 +43,9 @@ fn void main() @.str.6 = private unnamed_addr constant [4 x i8] c"%s\0A\00", align 1 @.str.7 = private unnamed_addr constant [4 x i8] c"Foo\00", align 1 @.str.8 = private unnamed_addr constant [4 x i8] c"%s\0A\00", align 1 -@.str.9 = private unnamed_addr constant [13 x i8] c"mymodule_Foo\00", align 1 +@.str.9 = private unnamed_addr constant [13 x i8] c"mymodule.Foo\00", align 1 @.str.10 = private unnamed_addr constant [4 x i8] c"%s\0A\00", align 1 -@.str.11 = private unnamed_addr constant [13 x i8] c"mymodule_Foo\00", align 1 +@.str.11 = private unnamed_addr constant [13 x i8] c"mymodule.Foo\00", align 1 @.str.12 = private unnamed_addr constant [4 x i8] c"%s\0A\00", align 1 @.str.13 = private unnamed_addr constant [12 x i8] c"mymodule::b\00", align 1 @.str.14 = private unnamed_addr constant [4 x i8] c"%s\0A\00", align 1 @@ -55,9 +55,9 @@ fn void main() @.str.18 = private unnamed_addr constant [4 x i8] c"%s\0A\00", align 1 @.str.19 = private unnamed_addr constant [2 x i8] c"b\00", align 1 @.str.20 = private unnamed_addr constant [4 x i8] c"%s\0A\00", align 1 -@.str.21 = private unnamed_addr constant [11 x i8] c"mymodule_b\00", align 1 +@.str.21 = private unnamed_addr constant [11 x i8] c"mymodule.b\00", align 1 @.str.22 = private unnamed_addr constant [4 x i8] c"%s\0A\00", align 1 -@.str.23 = private unnamed_addr constant [11 x i8] c"mymodule_b\00", align 1 +@.str.23 = private unnamed_addr constant [11 x i8] c"mymodule.b\00", align 1 @.str.24 = private unnamed_addr constant [4 x i8] c"%s\0A\00", align 1 @.str.25 = private unnamed_addr constant [2 x i8] c"a\00", align 1 @.str.26 = private unnamed_addr constant [4 x i8] c"%s\0A\00", align 1 diff --git a/test/test_suite/compile_time_introspection/offsetof.c3t b/test/test_suite/compile_time_introspection/offsetof.c3t index 915dbaa64..9526bd136 100644 --- a/test/test_suite/compile_time_introspection/offsetof.c3t +++ b/test/test_suite/compile_time_introspection/offsetof.c3t @@ -43,8 +43,8 @@ int z0 = Foob.c.offsetof; int z03 = Foob.a.offsetof; // #expect: foo.ll -@foo_y = local_unnamed_addr global i16 16, align 2 -@foo_z = local_unnamed_addr global i32 116, align 4 -@foo_w = local_unnamed_addr global i32 116, align 4 -@foo_z0 = local_unnamed_addr global i32 0, align 4 -@foo_z03 = local_unnamed_addr global i32 0, align 4 +@foo.y = local_unnamed_addr global i16 16, align 2 +@foo.z = local_unnamed_addr global i32 116, align 4 +@foo.w = local_unnamed_addr global i32 116, align 4 +@foo.z0 = local_unnamed_addr global i32 0, align 4 +@foo.z03 = local_unnamed_addr global i32 0, align 4 diff --git a/test/test_suite/compile_time_introspection/qnameof.c3t b/test/test_suite/compile_time_introspection/qnameof.c3t index a091a1dcf..90d2bb3b5 100644 --- a/test/test_suite/compile_time_introspection/qnameof.c3t +++ b/test/test_suite/compile_time_introspection/qnameof.c3t @@ -22,8 +22,8 @@ fn void main() /* #expect: qnametest.ll -@"ct$qnametest_Blob" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 -@qnametest_x = local_unnamed_addr global i32 0, align 4 +@"ct$qnametest.Blob" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 +@qnametest.x = local_unnamed_addr global i32 0, align 4 @.str = private unnamed_addr constant [12 x i8] c"printf: %s\0A\00", align 1 @.str.1 = private unnamed_addr constant [7 x i8] c"printf\00", align 1 @.str.2 = private unnamed_addr constant [13 x i8] c"printfq: %s\0A\00", align 1 @@ -43,7 +43,7 @@ fn void main() @.str.16 = private unnamed_addr constant [15 x i8] c"Blob**[3]: %s\0A\00", align 1 @.str.17 = private unnamed_addr constant [10 x i8] c"Blob**[3]\00", align 1 -define void @qnametest_main() #0 { +define void @qnametest.main() #0 { entry: %help = alloca i32, align 4 store i32 0, ptr %help, align 4 diff --git a/test/test_suite/compile_time_introspection/sizeof.c3t b/test/test_suite/compile_time_introspection/sizeof.c3t index 531ab71eb..772d36ae2 100644 --- a/test/test_suite/compile_time_introspection/sizeof.c3t +++ b/test/test_suite/compile_time_introspection/sizeof.c3t @@ -48,19 +48,19 @@ struct Foo // #expect: foo.ll -@foo_x = local_unnamed_addr global i64 64, align 8 -@foo_y = local_unnamed_addr global i16 64, align 2 -@foo_z = local_unnamed_addr global i32 64, align 4 -@foo_w = local_unnamed_addr global i32 64, align 4 -@foo_v = local_unnamed_addr global i32 1, align 4 -@foo_x1 = local_unnamed_addr global i32 8, align 4 -@foo_y1 = local_unnamed_addr global i32 2, align 4 -@foo_a = local_unnamed_addr global i32 60, align 4 -@foo_b = local_unnamed_addr global i32 5, align 4 -@foo_c = local_unnamed_addr global i32 5, align 4 -@foo_d = local_unnamed_addr global i32 1600, align 4 -@foo_e = local_unnamed_addr global i32 8, align 4 -@foo_a2 = local_unnamed_addr global i32 60, align 4 -@foo_a3 = local_unnamed_addr global i32 60, align 4 -@foo_a4 = local_unnamed_addr global i32 60, align 4 -@foo_a5 = local_unnamed_addr global i32 60, align 4 \ No newline at end of file +@foo.x = local_unnamed_addr global i64 64, align 8 +@foo.y = local_unnamed_addr global i16 64, align 2 +@foo.z = local_unnamed_addr global i32 64, align 4 +@foo.w = local_unnamed_addr global i32 64, align 4 +@foo.v = local_unnamed_addr global i32 1, align 4 +@foo.x1 = local_unnamed_addr global i32 8, align 4 +@foo.y1 = local_unnamed_addr global i32 2, align 4 +@foo.a = local_unnamed_addr global i32 60, align 4 +@foo.b = local_unnamed_addr global i32 5, align 4 +@foo.c = local_unnamed_addr global i32 5, align 4 +@foo.d = local_unnamed_addr global i32 1600, align 4 +@foo.e = local_unnamed_addr global i32 8, align 4 +@foo.a2 = local_unnamed_addr global i32 60, align 4 +@foo.a3 = local_unnamed_addr global i32 60, align 4 +@foo.a4 = local_unnamed_addr global i32 60, align 4 +@foo.a5 = local_unnamed_addr global i32 60, align 4 \ No newline at end of file diff --git a/test/test_suite/constants/byte_literals.c3t b/test/test_suite/constants/byte_literals.c3t index 211c5974c..1a68db76d 100644 --- a/test/test_suite/constants/byte_literals.c3t +++ b/test/test_suite/constants/byte_literals.c3t @@ -6,8 +6,8 @@ char[*] foo64 = b64"SGVsbG8gV29ybGQ="; // #expect: byte_literals.ll -@byte_literals_foob = local_unnamed_addr global [1 x i8] c"\A0", align 1 -@byte_literals_fooz = local_unnamed_addr global [7 x i8] c"\00\AA\BB\CC\DD\EE\FF", align 1 -@byte_literals_fooy = local_unnamed_addr global [4 x i8] c"\DE\AD\BE\EF", align 1 -@byte_literals_foow = local_unnamed_addr global [5 x i8] c"EI#M\ED", align 1 -@byte_literals_foo64 = local_unnamed_addr global [11 x i8] c"Hello World", align 1 +@byte_literals.foob = local_unnamed_addr global [1 x i8] c"\A0", align 1 +@byte_literals.fooz = local_unnamed_addr global [7 x i8] c"\00\AA\BB\CC\DD\EE\FF", align 1 +@byte_literals.fooy = local_unnamed_addr global [4 x i8] c"\DE\AD\BE\EF", align 1 +@byte_literals.foow = local_unnamed_addr global [5 x i8] c"EI#M\ED", align 1 +@byte_literals.foo64 = local_unnamed_addr global [11 x i8] c"Hello World", align 1 diff --git a/test/test_suite/constants/char_literals.c3t b/test/test_suite/constants/char_literals.c3t index a4ed8ce35..c4bbb0d6b 100644 --- a/test/test_suite/constants/char_literals.c3t +++ b/test/test_suite/constants/char_literals.c3t @@ -13,12 +13,12 @@ char i = '\e'; // #expect: test.ll -@test_a = local_unnamed_addr global i8 32, align 1 -@test_b = local_unnamed_addr global i8 13, align 1 -@test_c = local_unnamed_addr global i8 9, align 1 -@test_d = local_unnamed_addr global i8 10, align 1 -@test_e = local_unnamed_addr global i8 0, align 1 -@test_f = local_unnamed_addr global i8 39, align 1 -@test_g = local_unnamed_addr global i8 34, align 1 -@test_h = local_unnamed_addr global i8 92, align 1 -@test_i = local_unnamed_addr global i8 27, align 1 +@test.a = local_unnamed_addr global i8 32, align 1 +@test.b = local_unnamed_addr global i8 13, align 1 +@test.c = local_unnamed_addr global i8 9, align 1 +@test.d = local_unnamed_addr global i8 10, align 1 +@test.e = local_unnamed_addr global i8 0, align 1 +@test.f = local_unnamed_addr global i8 39, align 1 +@test.g = local_unnamed_addr global i8 34, align 1 +@test.h = local_unnamed_addr global i8 92, align 1 +@test.i = local_unnamed_addr global i8 27, align 1 diff --git a/test/test_suite/constants/const_var_copy.c3t b/test/test_suite/constants/const_var_copy.c3t index 045a7cf47..739041889 100644 --- a/test/test_suite/constants/const_var_copy.c3t +++ b/test/test_suite/constants/const_var_copy.c3t @@ -11,15 +11,15 @@ fn void test(int z) /* #expect: foo.ll -@foo_FOO = local_unnamed_addr constant { [50 x i8], i8, [49 x i8] } { [50 x i8] zeroinitializer, i8 1, [49 x i8] zeroinitializer }, align 16 -@foo_BAR = local_unnamed_addr constant <4 x i32> , align 16 +@foo.FOO = local_unnamed_addr constant { [50 x i8], i8, [49 x i8] } { [50 x i8] zeroinitializer, i8 1, [49 x i8] zeroinitializer }, align 16 +@foo.BAR = local_unnamed_addr constant <4 x i32> , align 16 -define void @foo_test(i32 %0) #0 { +define void @foo.test(i32 %0) #0 { entry: %s = alloca i8, align 1 %zd = alloca i32, align 4 %sisiext = sext i32 %0 to i64 - %1 = getelementptr inbounds [100 x i8], ptr @foo_FOO, i64 0, i64 %sisiext + %1 = getelementptr inbounds [100 x i8], ptr @foo.FOO, i64 0, i64 %sisiext %2 = load i8, ptr %1, align 1 store i8 %2, ptr %s, align 1 %sisiext1 = sext i32 %0 to i64 diff --git a/test/test_suite/constants/constants.c3t b/test/test_suite/constants/constants.c3t index e3ed81a6c..dcefe60b3 100644 --- a/test/test_suite/constants/constants.c3t +++ b/test/test_suite/constants/constants.c3t @@ -19,16 +19,16 @@ fn void test() /* #expect: constants.ll -@constants_AA = protected unnamed_addr constant i8 -1, align 1 -@constants_BB = local_unnamed_addr constant i8 -56, align 1 -@constants_CC = protected unnamed_addr constant i32 -1, align 4 -@constants_DD = protected unnamed_addr constant i32 -1, align 4 -@constants_FOO = protected unnamed_addr constant i32 -1, align 4 -@constants_x = protected unnamed_addr global i32 255, align 4 -@constants_z = protected unnamed_addr global i32 -1, align 4 -@constants_w = protected unnamed_addr global i8 -1, align 1 -@constants_v = protected unnamed_addr global i16 -1, align 2 -@constants_z2 = protected unnamed_addr global i32 -1, align 4 +@constants.AA = protected unnamed_addr constant i8 -1, align 1 +@constants.BB = local_unnamed_addr constant i8 -56, align 1 +@constants.CC = protected unnamed_addr constant i32 -1, align 4 +@constants.DD = protected unnamed_addr constant i32 -1, align 4 +@constants.FOO = protected unnamed_addr constant i32 -1, align 4 +@constants.x = protected unnamed_addr global i32 255, align 4 +@constants.z = protected unnamed_addr global i32 -1, align 4 +@constants.w = protected unnamed_addr global i8 -1, align 1 +@constants.v = protected unnamed_addr global i16 -1, align 2 +@constants.z2 = protected unnamed_addr global i32 -1, align 4 entry: %xx = alloca i32, align 4 diff --git a/test/test_suite/constants/float_type.c3t b/test/test_suite/constants/float_type.c3t index 5ee96b84e..262fd0652 100644 --- a/test/test_suite/constants/float_type.c3t +++ b/test/test_suite/constants/float_type.c3t @@ -6,6 +6,6 @@ uint f64 = $typeof(1.0f64).sizeof; /* #expect: test.ll -@test_f0 = local_unnamed_addr global i32 4, align 4 -@test_f32 = local_unnamed_addr global i32 4, align 4 -@test_f64 = local_unnamed_addr global i32 8, align 4 \ No newline at end of file +@test.f0 = local_unnamed_addr global i32 4, align 4 +@test.f32 = local_unnamed_addr global i32 4, align 4 +@test.f64 = local_unnamed_addr global i32 8, align 4 \ No newline at end of file diff --git a/test/test_suite/constants/init_order.c3t b/test/test_suite/constants/init_order.c3t index e4390261a..20e6562a1 100644 --- a/test/test_suite/constants/init_order.c3t +++ b/test/test_suite/constants/init_order.c3t @@ -20,6 +20,6 @@ const B = foo(); /* #expect: test.ll -@test_Z = local_unnamed_addr constant i32 1, align 4 -@test_B = local_unnamed_addr constant i32 223, align 4 -@test_A = local_unnamed_addr constant i32 222, align 4 \ No newline at end of file +@test.Z = local_unnamed_addr constant i32 1, align 4 +@test.B = local_unnamed_addr constant i32 223, align 4 +@test.A = local_unnamed_addr constant i32 222, align 4 \ No newline at end of file diff --git a/test/test_suite/contracts/simple_test.c3t b/test/test_suite/contracts/simple_test.c3t index 6251f3a4f..379be7fc9 100644 --- a/test/test_suite/contracts/simple_test.c3t +++ b/test/test_suite/contracts/simple_test.c3t @@ -43,7 +43,7 @@ fn void main() /* #expect: simple_test.ll -define void @simple_test_test(ptr %0, i32 %1) #0 { +define void @simple_test.test(ptr %0, i32 %1) #0 { entry: %gt = icmp sgt i32 %1, 100 call void @llvm.assume(i1 %gt) @@ -51,7 +51,7 @@ entry: ret void } -define i32 @simple_test_test2(ptr %0, i32 %1) #0 { +define i32 @simple_test.test2(ptr %0, i32 %1) #0 { entry: %gt = icmp sgt i32 %1, 100 call void @llvm.assume(i1 %gt) @@ -61,7 +61,7 @@ entry: ret i32 %1 } -define i32 @simple_test_test3(i32 %0) #0 { +define i32 @simple_test.test3(i32 %0) #0 { entry: %gt = icmp sgt i32 %0, 0 call void @llvm.assume(i1 %gt) @@ -71,13 +71,13 @@ entry: ret i32 %add } -define void @simple_test_main() #0 { +define void @simple_test.main() #0 { entry: %fooofke = alloca i32, align 4 store i32 0, ptr %fooofke, align 4 - call void @simple_test_test(ptr %fooofke, i32 330) - %0 = call i32 @simple_test_test2(ptr %fooofke, i32 150) - %1 = call i32 @simple_test_test3(i32 123) + call void @simple_test.test(ptr %fooofke, i32 330) + %0 = call i32 @simple_test.test2(ptr %fooofke, i32 150) + %1 = call i32 @simple_test.test3(i32 123) %2 = load i32, ptr %fooofke, align 4 call void (ptr, ...) @printf(ptr @.str, i32 %2) ret void @@ -85,6 +85,6 @@ entry: define i32 @main(i32 %0, ptr %1) #0 { entry: - call void @simple_test_main() + call void @simple_test.main() ret i32 0 } \ No newline at end of file diff --git a/test/test_suite/debug_symbols/constants.c3t b/test/test_suite/debug_symbols/constants.c3t index d1b3062a8..23f86fb72 100644 --- a/test/test_suite/debug_symbols/constants.c3t +++ b/test/test_suite/debug_symbols/constants.c3t @@ -7,22 +7,22 @@ const FOO @private = ~(uint)(0); /* #expect: constants.ll -@constants_AA = protected unnamed_addr constant i8 1, align 1 -@constants_BB = local_unnamed_addr constant i8 -56, align 1 -@constants_CC = protected unnamed_addr constant i32 -1, align 4 -@constants_FOO = protected unnamed_addr constant i32 -1, align 4 +@constants.AA = protected unnamed_addr constant i8 1, align 1 +@constants.BB = local_unnamed_addr constant i8 -56, align 1 +@constants.CC = protected unnamed_addr constant i32 -1, align 4 +@constants.FOO = protected unnamed_addr constant i32 -1, align 4 !llvm.dbg.cu = !{!0} -!0 = distinct !DICompileUnit(language: DW_LANG_C, file: !1, producer: "c3c", isOptimized: false, runtimeVersion: 1, emissionKind: FullDebug +!0 = distinct !DICompileUnit(language: DW_LANG_C, file: !1, producer: "c3c", isOptimized: false, runtimeVersion: 1, emissionKind: FullDebug, globals: !2, splitDebugInlining: false) !1 = !DIFile(filename: "constants.c3", !DIGlobalVariableExpression -distinct !DIGlobalVariable(name: "AA", linkageName: "constants_AA", scope: !1, file: !1, line: 1 +distinct !DIGlobalVariable(name: "AA", linkageName: "constants.AA", scope: !1, !DIBasicType(name: "char", size: 8, encoding: DW_ATE_unsigned_char) !DIGlobalVariableExpression -distinct !DIGlobalVariable(name: "BB", linkageName: "constants_BB", scope: !1, file: !1, line: 2 +distinct !DIGlobalVariable(name: "BB", linkageName: "constants.BB", scope: !1, file: !1, line: 2 !DIGlobalVariableExpression -distinct !DIGlobalVariable(name: "CC", linkageName: "constants_CC", scope: !1, file: !1, line: 3 -!DIBasicType(name: "uint", size: 32, encoding: DW_ATE_unsigned) -!DIGlobalVariableExpression -distinct !DIGlobalVariable(name: "FOO", linkageName: "constants_FOO", scope: !1, file: !1, line: 4 +distinct !DIGlobalVariable(name: "CC", linkageName: "constants.CC", scope: !1, file: !1, line: 3 + !DIBasicType(name: "uint", size: 32, encoding: DW_ATE_unsigned) + !DIGlobalVariableExpression + distinct !DIGlobalVariable(name: "FOO", linkageName: "constants.FOO", scope: !1, file: !1, line: diff --git a/test/test_suite/defer/defer_and_expr_block.c3t b/test/test_suite/defer/defer_and_expr_block.c3t index 5c8c9269b..af90a083e 100644 --- a/test/test_suite/defer/defer_and_expr_block.c3t +++ b/test/test_suite/defer/defer_and_expr_block.c3t @@ -20,7 +20,7 @@ fn void main() /* #expect: foo.ll -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %blockret = alloca i32, align 4 br label %if.then diff --git a/test/test_suite/defer/defer_static_var.c3t b/test/test_suite/defer/defer_static_var.c3t index 7712cfb52..60197edc9 100644 --- a/test/test_suite/defer/defer_static_var.c3t +++ b/test/test_suite/defer/defer_static_var.c3t @@ -47,7 +47,7 @@ fn void main() @"main$y.7" = internal unnamed_addr global i32 0, align 4 @"main$y.12" = internal unnamed_addr global i32 0, align 4 -define i32 @foo_foo(i32 %0) #0 { +define i32 @foo.foo(i32 %0) #0 { entry: %gt = icmp sgt i32 %0, 0 br i1 %gt, label %if.then, label %if.exit @@ -69,7 +69,7 @@ if.exit: ; preds = %entry ret i32 %0 } -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %x = alloca i32, align 4 %i = alloca i32, align 4 @@ -77,9 +77,9 @@ entry: %i4 = alloca i32, align 4 %x15 = alloca i32, align 4 %i16 = alloca i32, align 4 - %0 = call i32 @foo_foo(i32 1) - %1 = call i32 @foo_foo(i32 2) - %2 = call i32 @foo_foo(i32 -2) + %0 = call i32 @foo.foo(i32 1) + %1 = call i32 @foo.foo(i32 2) + %2 = call i32 @foo.foo(i32 -2) store i32 0, ptr %x, align 4 %3 = load i32, ptr %x, align 4 call void (ptr, ...) @printf(ptr @.str.2, i32 %3) diff --git a/test/test_suite/enumerations/compile_time.c3t b/test/test_suite/enumerations/compile_time.c3t index 684f8ef3b..bf18c25b4 100644 --- a/test/test_suite/enumerations/compile_time.c3t +++ b/test/test_suite/enumerations/compile_time.c3t @@ -11,6 +11,6 @@ int myenum_sizeof = MyEnum.sizeof; /* #expect: compile_time.ll -@compile_time_myenum_elements = local_unnamed_addr global i32 3, align 4 -@compile_time_myenum_alignof = local_unnamed_addr global i32 2, align 4 -@compile_time_myenum_sizeof = local_unnamed_addr global i32 2, align 4 \ No newline at end of file +@compile_time.myenum_elements = local_unnamed_addr global i32 3, align 4 +@compile_time.myenum_alignof = local_unnamed_addr global i32 2, align 4 +@compile_time.myenum_sizeof = local_unnamed_addr global i32 2, align 4 \ No newline at end of file diff --git a/test/test_suite/enumerations/enum_associated_value.c3t b/test/test_suite/enumerations/enum_associated_value.c3t index 980cd93b1..570bf822e 100644 --- a/test/test_suite/enumerations/enum_associated_value.c3t +++ b/test/test_suite/enumerations/enum_associated_value.c3t @@ -19,15 +19,15 @@ fn void main() /* #expect: test.ll @"ct$uint" = linkonce constant %.introspect { i8 3, i64 4, i64 0, i64 0, [0 x i64] zeroinitializer }, align 8 -@"ct$test_Foo" = linkonce constant { i8, i64, i64, i64, [2 x %"char[]"] } { i8 8, i64 4, i64 ptrtoint (ptr @"ct$uint" to i64), i64 2, [2 x %"char[]"] [%"char[]" { ptr @.enum.0, i64 1 }, %"char[]" { ptr @.enum.1, i64 1 }] }, align 8 -@"test_Foo$val" = linkonce constant [2 x i32] [i32 123, i32 333], align 4 +@"ct$test.Foo" = linkonce constant { i8, i64, i64, i64, [2 x %"char[]"] } { i8 8, i64 4, i64 ptrtoint (ptr @"ct$uint" to i64), i64 2, [2 x %"char[]"] [%"char[]" { ptr @.enum.0, i64 1 }, %"char[]" { ptr @.enum.1, i64 1 }] }, align 8 +@"test.Foo$val" = linkonce constant [2 x i32] [i32 123, i32 333], align 4 @.str = private unnamed_addr constant [9 x i8] c"Number A\00", align 1 @.str.1 = private unnamed_addr constant [9 x i8] c"Number B\00", align 1 -@"test_Foo$testme" = linkonce constant [2 x ptr] [ptr @.str, ptr @.str.1], align 8 +@"test.Foo$testme" = linkonce constant [2 x ptr] [ptr @.str, ptr @.str.1], align 8 @.str.2 = private unnamed_addr constant [17 x i8] c"%d (%s) %d (%s)\0A\00", align 1 ; Function Attrs: nounwind -define void @test_main() #0 { +define void @test.main() #0 { entry: %x = alloca i32, align 4 %f = alloca i32, align 4 @@ -36,16 +36,16 @@ entry: store i32 1, ptr %f, align 4 store i32 0, ptr %g, align 4 %0 = load i32, ptr %f, align 4 - %1 = getelementptr inbounds [2 x i32], ptr @"test_Foo$val", i32 0, i32 %0 + %1 = getelementptr inbounds [2 x i32], ptr @"test.Foo$val", i32 0, i32 %0 %2 = load i32, ptr %1, align 4 %3 = load i32, ptr %f, align 4 - %4 = getelementptr inbounds [2 x ptr], ptr @"test_Foo$testme", i32 0, i32 %3 + %4 = getelementptr inbounds [2 x ptr], ptr @"test.Foo$testme", i32 0, i32 %3 %5 = load ptr, ptr %4, align 8 %6 = load i32, ptr %g, align 4 - %7 = getelementptr inbounds [2 x i32], ptr @"test_Foo$val", i32 0, i32 %6 + %7 = getelementptr inbounds [2 x i32], ptr @"test.Foo$val", i32 0, i32 %6 %8 = load i32, ptr %7, align 4 %9 = load i32, ptr %g, align 4 - %10 = getelementptr inbounds [2 x ptr], ptr @"test_Foo$testme", i32 0, i32 %9 + %10 = getelementptr inbounds [2 x ptr], ptr @"test.Foo$testme", i32 0, i32 %9 %11 = load ptr, ptr %10, align 8 %12 = call i32 (ptr, ...) @printf(ptr @.str.2, i32 %2, ptr %5, i32 %8, ptr %11) ret void diff --git a/test/test_suite/enumerations/enum_associated_values_other.c3t b/test/test_suite/enumerations/enum_associated_values_other.c3t index 38b0b69af..a307bb496 100644 --- a/test/test_suite/enumerations/enum_associated_values_other.c3t +++ b/test/test_suite/enumerations/enum_associated_values_other.c3t @@ -24,33 +24,33 @@ enum Foo : int(String val) /* #expect: abc.ll -@"ct$abc_Abc" = linkonce constant %.introspect { i8 10, i64 4, i64 0, i64 1, [0 x i64] zeroinitializer }, align 8 +@"ct$abc.Abc" = linkonce constant %.introspect { i8 10, i64 4, i64 0, i64 1, [0 x i64] zeroinitializer }, align 8 @.enum.0 = internal constant [4 x i8] c"ABC\00", align 1 @.enum.1 = internal constant [4 x i8] c"DEF\00", align 1 @"ct$int" = linkonce constant %.introspect { i8 2, i64 4, i64 0, i64 0, [0 x i64] zeroinitializer }, align 8 -@"ct$abc_Foo" = linkonce constant { i8, i64, i64, i64, [2 x %"char[]"] } { i8 8, i64 4, i64 ptrtoint (ptr @"ct$int" to i64), i64 2, [2 x %"char[]"] [%"char[]" { ptr @.enum.0, i64 3 }, %"char[]" { ptr @.enum.1, i64 3 }] }, align 8 +@"ct$abc.Foo" = linkonce constant { i8, i64, i64, i64, [2 x %"char[]"] } { i8 8, i64 4, i64 ptrtoint (ptr @"ct$int" to i64), i64 2, [2 x %"char[]"] [%"char[]" { ptr @.enum.0, i64 3 }, %"char[]" { ptr @.enum.1, i64 3 }] }, align 8 @.str = private unnamed_addr constant [6 x i8] c"hello\00", align 1 @.str.1 = private unnamed_addr constant [6 x i8] c"world\00", align 1 -@"abc_Foo$val" = linkonce constant [2 x %"char[]"] [%"char[]" { ptr @.str, i64 5 }, %"char[]" { ptr @.str.1, i64 5 }], align 8 -@abc_dabc = global i32 0, align 4 +@"abc.Foo$val" = linkonce constant [2 x %"char[]"] [%"char[]" { ptr @.str, i64 5 }, %"char[]" { ptr @.str.1, i64 5 }], align 8 +@abc.dabc = global i32 0, align 4 + // #expect: test.ll - -@"ct$abc_Abc" = linkonce constant %.introspect { i8 10, i64 4, i64 0, i64 1, [0 x i64] zeroinitializer }, align 8 -@abc_dabc = external global i32, align 4 +@"ct$abc.Abc" = linkonce constant %.introspect { i8 10, i64 4, i64 0, i64 1, [0 x i64] zeroinitializer }, align 8 +@abc.dabc = external global i32, align 4 @.enum.0 = internal constant [4 x i8] c"ABC\00", align 1 @.enum.1 = internal constant [4 x i8] c"DEF\00", align 1 @"ct$int" = linkonce constant %.introspect { i8 2, i64 4, i64 0, i64 0, [0 x i64] zeroinitializer }, align 8 -@"ct$abc_Foo" = linkonce constant { i8, i64, i64, i64, [2 x %"char[]"] } { i8 8, i64 4, i64 ptrtoint (ptr @"ct$int" to i64), i64 2, [2 x %"char[]"] [%"char[]" { ptr @.enum.0, i64 3 }, %"char[]" { ptr @.enum.1, i64 3 }] }, align 8 +@"ct$abc.Foo" = linkonce constant { i8, i64, i64, i64, [2 x %"char[]"] } { i8 8, i64 4, i64 ptrtoint (ptr @"ct$int" to i64), i64 2, [2 x %"char[]"] [%"char[]" { ptr @.enum.0, i64 3 }, %"char[]" { ptr @.enum.1, i64 3 }] }, align 8 @.str = private unnamed_addr constant [6 x i8] c"hello\00", align 1 @.str.1 = private unnamed_addr constant [6 x i8] c"world\00", align 1 -@"abc_Foo$val" = linkonce constant [2 x %"char[]"] [%"char[]" { ptr @.str, i64 5 }, %"char[]" { ptr @.str.1, i64 5 }], align 8 +@"abc.Foo$val" = linkonce constant [2 x %"char[]"] [%"char[]" { ptr @.str, i64 5 }, %"char[]" { ptr @.str.1, i64 5 }], align 8 @.str.2 = private unnamed_addr constant [3 x i8] c"%s\00", align 1 @"ct$char" = linkonce constant %.introspect { i8 3, i64 1, i64 0, i64 0, [0 x i64] zeroinitializer }, align 8 @"ct$sa$char" = linkonce constant %.introspect { i8 16, i64 16, i64 ptrtoint (ptr @"ct$char" to i64), i64 0, [0 x i64] zeroinitializer }, align 8 -define void @test_main(ptr %0, i64 %1) #0 { +define void @test.main(ptr %0, i64 %1) #0 { entry: %args = alloca %"char[][]", align 8 %y = alloca i64, align 8 @@ -62,16 +62,16 @@ entry: store ptr %0, ptr %args, align 8 %ptroffset = getelementptr inbounds i64, ptr %args, i64 1 store i64 %1, ptr %ptroffset, align 8 - store i64 ptrtoint (ptr @"ct$abc_Abc" to i64), ptr %y, align 8 - store ptr @abc_dabc, ptr %x, align 8 + store i64 ptrtoint (ptr @"ct$abc.Abc" to i64), ptr %y, align 8 + store ptr @abc.dabc, ptr %x, align 8 store i32 1, ptr %a, align 4 %2 = load i32, ptr %a, align 4 - %3 = getelementptr inbounds [2 x %"char[]"], ptr @"abc_Foo$val", i32 0, i32 %2 + %3 = getelementptr inbounds [2 x %"char[]"], ptr @"abc.Foo$val", i32 0, i32 %2 call void @llvm.memcpy.p0.p0.i32(ptr align 8 %z, ptr align 8 %3, i32 16, i1 false) %4 = insertvalue %variant undef, ptr %z, 0 %5 = insertvalue %variant %4, i64 ptrtoint (ptr @"ct$sa$char" to i64), 1 %6 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %5, ptr %6, align 16 - %7 = call i64 @std_io_printfn(ptr %retparam, ptr @.str.2, i64 2, ptr %varargslots, i64 1) + %7 = call i64 @std_io.printfn(ptr %retparam, ptr @.str.2, i64 2, ptr %varargslots, i64 1) ret void } \ No newline at end of file diff --git a/test/test_suite/enumerations/enum_cast.c3t b/test/test_suite/enumerations/enum_cast.c3t index b19543992..f6c9c4a25 100644 --- a/test/test_suite/enumerations/enum_cast.c3t +++ b/test/test_suite/enumerations/enum_cast.c3t @@ -35,7 +35,7 @@ fn void test() /* #expect: test.ll -define void @test_test2() #0 { +define void @test.test2() #0 { entry: %ww = alloca i8, align 1 %x = alloca i8, align 1 @@ -47,7 +47,7 @@ entry: ret void } -define void @test_test() #0 { +define void @test.test() #0 { entry: %b = alloca i8, align 1 %z = alloca i32, align 4 diff --git a/test/test_suite/enumerations/enum_values.c3t b/test/test_suite/enumerations/enum_values.c3t index 7e69c75da..da5b1aa8b 100644 --- a/test/test_suite/enumerations/enum_values.c3t +++ b/test/test_suite/enumerations/enum_values.c3t @@ -20,11 +20,11 @@ fn void test(int x) %"Foo[]" = type { ptr, i64 } -@test_zfok = local_unnamed_addr global i32 0, align 4 +@test.zfok = local_unnamed_addr global i32 0, align 4 @.taddr = private global [2 x i32] [i32 0, i32 1], align 4 -@test_zw = local_unnamed_addr global %"Foo[]" { ptr @.taddr, i64 2 }, align 8 +@test.zw = local_unnamed_addr global %"Foo[]" { ptr @.taddr, i64 2 }, align 8 -define void @test_test(i32 %0) #0 { +define void @test.test(i32 %0) #0 { entry: %zonk = alloca i32, align 4 %literal = alloca [2 x i32], align 4 diff --git a/test/test_suite/enumerations/simple_inference.c3t b/test/test_suite/enumerations/simple_inference.c3t index d2e93de8c..018c82eda 100644 --- a/test/test_suite/enumerations/simple_inference.c3t +++ b/test/test_suite/enumerations/simple_inference.c3t @@ -14,7 +14,7 @@ fn void test() /* #expect: simple_inference.ll -define void @simple_inference_test() #0 { +define void @simple_inference.test() #0 { entry: %h = alloca i32, align 4 store i32 1, ptr %h, align 4 diff --git a/test/test_suite/errors/anyerr_void.c3t b/test/test_suite/errors/anyerr_void.c3t index 05429fd3a..00d77638b 100644 --- a/test/test_suite/errors/anyerr_void.c3t +++ b/test/test_suite/errors/anyerr_void.c3t @@ -26,13 +26,13 @@ fn void main() /* #expect: anyerr_void.ll -define i64 @anyerr_void_errorThing() #0 { +define i64 @anyerr_void.errorThing() #0 { entry: - ret i64 ptrtoint (ptr @"anyerr_void_MyError$BAR" to i64) + ret i64 ptrtoint (ptr @"anyerr_void.MyError$BAR" to i64) } ; Function Attrs: nounwind -define i64 @anyerr_void_errorThing2() #0 { +define i64 @anyerr_void.errorThing2() #0 { entry: %reterr = alloca i64, align 8 ret i64 0 @@ -42,13 +42,13 @@ entry: declare void @printf(ptr, ...) #0 ; Function Attrs: nounwind -define void @anyerr_void_main() #0 { +define void @anyerr_void.main() #0 { entry: %z = alloca i64, align 8 %error_var = alloca i64, align 8 %error_var1 = alloca i64, align 8 store i64 0, ptr %error_var, align 8 - %0 = call i64 @anyerr_void_errorThing() + %0 = call i64 @anyerr_void.errorThing() %not_err = icmp eq i64 %0, 0 %1 = call i1 @llvm.expect.i1(i1 %not_err, i1 true) br i1 %1, label %after_check, label %assign_optional @@ -65,10 +65,10 @@ noerr_block: ; preds = %after_check, %assig store i64 %2, ptr %z, align 8 %3 = load i64, ptr %z, align 8 call void (ptr, ...) @printf(ptr @.str, i64 %3) - call void (ptr, ...) @printf(ptr @.str.2, i64 ptrtoint (ptr @"anyerr_void_MyError$BAR" to i64)) - call void (ptr, ...) @printf(ptr @.str.3, i64 ptrtoint (ptr @"anyerr_void_MyError$FOO" to i64)) + call void (ptr, ...) @printf(ptr @.str.2, i64 ptrtoint (ptr @"anyerr_void.MyError$BAR" to i64)) + call void (ptr, ...) @printf(ptr @.str.3, i64 ptrtoint (ptr @"anyerr_void.MyError$FOO" to i64)) store i64 0, ptr %error_var1, align 8 - %4 = call i64 @anyerr_void_errorThing2() + %4 = call i64 @anyerr_void.errorThing2() %not_err2 = icmp eq i64 %4, 0 %5 = call i1 @llvm.expect.i1(i1 %not_err2, i1 true) br i1 %5, label %after_check4, label %assign_optional3 diff --git a/test/test_suite/errors/else_checks.c3t b/test/test_suite/errors/else_checks.c3t index c5a5ef48d..6f305e0c6 100644 --- a/test/test_suite/errors/else_checks.c3t +++ b/test/test_suite/errors/else_checks.c3t @@ -17,7 +17,7 @@ fn void test() declare i64 @testError(ptr) #0 ; Function Attrs: nounwind -define void @else_checks_test() #0 { +define void @else_checks.test() #0 { entry: %x = alloca double, align 8 %retparam = alloca i32, align 4 diff --git a/test/test_suite/errors/error_introspect.c3t b/test/test_suite/errors/error_introspect.c3t index e574770ef..85e15491f 100644 --- a/test/test_suite/errors/error_introspect.c3t +++ b/test/test_suite/errors/error_introspect.c3t @@ -18,11 +18,11 @@ fn void main() /* #expect: foo.ll -@"foo_Foo$BAR" = linkonce constant %.fault { i64 ptrtoint (ptr @"ct$foo_Foo" to i64), %"char[]" { ptr @.fault, i64 3 } }, align 8 +@"foo.Foo$BAR" = linkonce constant %.fault { i64 ptrtoint (ptr @"ct$foo.Foo" to i64), %"char[]" { ptr @.fault, i64 3 } }, align 8 @.fault = internal constant [4 x i8] c"BAR\00", align 1 -@"foo_Foo$BAZ" = linkonce constant %.fault { i64 ptrtoint (ptr @"ct$foo_Foo" to i64), %"char[]" { ptr @.fault.1, i64 3 } }, align 8 +@"foo.Foo$BAZ" = linkonce constant %.fault { i64 ptrtoint (ptr @"ct$foo.Foo" to i64), %"char[]" { ptr @.fault.1, i64 3 } }, align 8 @.fault.1 = internal constant [4 x i8] c"BAZ\00", align 1 -@"ct$foo_Foo" = linkonce constant %.introspect { i8 9, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 +@"ct$foo.Foo" = linkonce constant %.introspect { i8 9, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 @.str = private unnamed_addr constant [4 x i8] c"BAR\00", align 1 @.str.2 = private unnamed_addr constant [4 x i8] c"BAZ\00", align 1 @.str.3 = private unnamed_addr constant [14 x i8] c"Foo.names: %s\00", align 1 @@ -30,7 +30,7 @@ fn void main() @"ct$sa$char" = linkonce constant %.introspect { i8 16, i64 16, i64 ptrtoint (ptr @"ct$char" to i64), i64 0, [0 x i64] zeroinitializer }, align 8 @"ct$sa$sa$char" = linkonce constant %.introspect { i8 16, i64 16, i64 ptrtoint (ptr @"ct$sa$char" to i64), i64 0, [0 x i64] zeroinitializer }, align 8 @.str.4 = private unnamed_addr constant [15 x i8] c"Foo.values: %s\00", align 1 -@"ct$a2$foo_Foo" = linkonce constant %.introspect { i8 15, i64 16, i64 ptrtoint (ptr @"ct$foo_Foo" to i64), i64 2, [0 x i64] zeroinitializer }, align 8 +@"ct$a2$foo.Foo" = linkonce constant %.introspect { i8 15, i64 16, i64 ptrtoint (ptr @"ct$foo.Foo" to i64), i64 2, [0 x i64] zeroinitializer }, align 8 @.str.5 = private unnamed_addr constant [17 x i8] c"Foo.elements: %s\00", align 1 @"ct$long" = linkonce constant %.introspect { i8 2, i64 8, i64 0, i64 0, [0 x i64] zeroinitializer }, align 8 @@ -56,21 +56,21 @@ entry: %5 = insertvalue %variant %4, i64 ptrtoint (ptr @"ct$sa$sa$char" to i64), 1 %6 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %5, ptr %6, align 16 - %7 = call i64 @std_io_printfn(ptr %retparam, ptr @.str.3, i64 13, ptr %varargslots, i64 1) + %7 = call i64 @std_io.printfn(ptr %retparam, ptr @.str.3, i64 13, ptr %varargslots, i64 1) %8 = getelementptr inbounds [2 x i64], ptr %literal3, i64 0, i64 0 - store i64 ptrtoint (ptr @"foo_Foo$BAR" to i64), ptr %8, align 8 + store i64 ptrtoint (ptr @"foo.Foo$BAR" to i64), ptr %8, align 8 %9 = getelementptr inbounds [2 x i64], ptr %literal3, i64 0, i64 1 - store i64 ptrtoint (ptr @"foo_Foo$BAZ" to i64), ptr %9, align 8 + store i64 ptrtoint (ptr @"foo.Foo$BAZ" to i64), ptr %9, align 8 %10 = insertvalue %variant undef, ptr %literal3, 0 - %11 = insertvalue %variant %10, i64 ptrtoint (ptr @"ct$a2$foo_Foo" to i64), 1 + %11 = insertvalue %variant %10, i64 ptrtoint (ptr @"ct$a2$foo.Foo" to i64), 1 %12 = getelementptr inbounds [1 x %variant], ptr %varargslots2, i64 0, i64 0 store %variant %11, ptr %12, align 16 - %13 = call i64 @std_io_printfn(ptr %retparam1, ptr @.str.4, i64 14, ptr %varargslots2, i64 1) + %13 = call i64 @std_io.printfn(ptr %retparam1, ptr @.str.4, i64 14, ptr %varargslots2, i64 1) store i64 2, ptr %taddr, align 8 %14 = insertvalue %variant undef, ptr %taddr, 0 %15 = insertvalue %variant %14, i64 ptrtoint (ptr @"ct$long" to i64), 1 %16 = getelementptr inbounds [1 x %variant], ptr %varargslots5, i64 0, i64 0 store %variant %15, ptr %16, align 16 - %17 = call i64 @std_io_printfn(ptr %retparam4, ptr @.str.5, i64 16, ptr %varargslots5, i64 1) + %17 = call i64 @std_io.printfn(ptr %retparam4, ptr @.str.5, i64 16, ptr %varargslots5, i64 1) ret void } diff --git a/test/test_suite/errors/error_regression_2.c3t b/test/test_suite/errors/error_regression_2.c3t index 863f81d6e..84ef981c6 100644 --- a/test/test_suite/errors/error_regression_2.c3t +++ b/test/test_suite/errors/error_regression_2.c3t @@ -150,7 +150,7 @@ fn void main() /* #expect: test.ll -define void @test_Summary_print(ptr %0, ptr %1) #0 { +define void @test.Summary_print(ptr %0, ptr %1) #0 { entry: %title = alloca %"char[]", align 8 %2 = getelementptr inbounds %Summary, ptr %0, i32 0, i32 0 @@ -184,7 +184,7 @@ cond.phi: ; preds = %cond.rhs, %cond.lhs } ; Function Attrs: nounwind -define zeroext i8 @test_contains(ptr %0, i64 %1, ptr %2, i64 %3) #0 { +define zeroext i8 @test.contains(ptr %0, i64 %1, ptr %2, i64 %3) #0 { entry: %haystack = alloca %"char[]", align 8 %needle = alloca %"char[]", align 8 @@ -260,7 +260,7 @@ loop.exit: ; preds = %loop.cond } ; Function Attrs: nounwind -define i64 @test_readDoc(ptr %0, ptr %1, i64 %2) #0 { +define i64 @test.readDoc(ptr %0, ptr %1, i64 %2) #0 { entry: %url = alloca %"char[]", align 8 %reterr = alloca i64, align 8 @@ -298,19 +298,19 @@ entry: %lo = load ptr, ptr %3, align 8 %4 = getelementptr inbounds %"char[]", ptr %url, i32 0, i32 1 %hi = load i64, ptr %4, align 8 - %5 = call i8 @test_contains(ptr %lo, i64 %hi, ptr @.str, i64 4) + %5 = call i8 @test.contains(ptr %lo, i64 %hi, ptr @.str, i64 4) %6 = trunc i8 %5 to i1 br i1 %6, label %if.then, label %if.exit if.then: ; preds = %entry - ret i64 ptrtoint (ptr @"test_ReadError$BAD_READ" to i64) + ret i64 ptrtoint (ptr @"test.ReadError$BAD_READ" to i64) if.exit: ; preds = %entry %7 = getelementptr inbounds %"char[]", ptr %url, i32 0, i32 0 %lo1 = load ptr, ptr %7, align 8 %8 = getelementptr inbounds %"char[]", ptr %url, i32 0, i32 1 %hi2 = load i64, ptr %8, align 8 - %9 = call i8 @test_contains(ptr %lo1, i64 %hi2, ptr @.str.3, i64 12) + %9 = call i8 @test.contains(ptr %lo1, i64 %hi2, ptr @.str.3, i64 12) %10 = trunc i8 %9 to i1 br i1 %10, label %if.then3, label %if.exit4 @@ -325,7 +325,7 @@ if.exit4: ; preds = %if.exit %lo5 = load ptr, ptr %12, align 8 %13 = getelementptr inbounds %"char[]", ptr %url, i32 0, i32 1 %hi6 = load i64, ptr %13, align 8 - %14 = call i8 @test_contains(ptr %lo5, i64 %hi6, ptr @.str.4, i64 13) + %14 = call i8 @test.contains(ptr %lo5, i64 %hi6, ptr @.str.4, i64 13) %15 = trunc i8 %14 to i1 br i1 %15, label %if.then7, label %if.exit13 @@ -334,14 +334,14 @@ if.then7: ; preds = %if.exit4 %17 = getelementptr inbounds %Head, ptr %literal10, i32 0, i32 0 store ptr null, ptr %17, align 8 call void @llvm.memcpy.p0.p0.i32(ptr align 8 %value, ptr align 8 %literal10, i32 8, i1 false) - %18 = call ptr @std_core_mem_malloc(i64 8) #3 + %18 = call ptr @std_core_mem.malloc(i64 8) #3 store ptr %18, ptr %temp, align 8 %19 = load ptr, ptr %temp, align 8 %not = icmp eq ptr %19, null br i1 %not, label %if.then11, label %if.exit12 if.then11: ; preds = %if.then7 - store i64 ptrtoint (ptr @"test_ReadError$OUT_OF_MEMORY" to i64), ptr %error_var, align 8 + store i64 ptrtoint (ptr @"test.ReadError$OUT_OF_MEMORY" to i64), ptr %error_var, align 8 br label %guard_block if.exit12: ; preds = %if.then7 @@ -364,7 +364,7 @@ if.exit13: ; preds = %if.exit4 %lo14 = load ptr, ptr %23, align 8 %24 = getelementptr inbounds %"char[]", ptr %url, i32 0, i32 1 %hi15 = load i64, ptr %24, align 8 - %25 = call i8 @test_contains(ptr %lo14, i64 %hi15, ptr @.str.5, i64 11) + %25 = call i8 @test.contains(ptr %lo14, i64 %hi15, ptr @.str.5, i64 11) %26 = trunc i8 %25 to i1 br i1 %26, label %if.then16, label %if.exit36 @@ -373,14 +373,14 @@ if.then16: ; preds = %if.exit13 store ptr null, ptr %literal21, align 8 %28 = getelementptr inbounds %Head, ptr %literal21, i32 0, i32 0 store %"char[]" zeroinitializer, ptr %value23, align 8 - %29 = call ptr @std_core_mem_malloc(i64 16) #3 + %29 = call ptr @std_core_mem.malloc(i64 16) #3 store ptr %29, ptr %temp24, align 8 %30 = load ptr, ptr %temp24, align 8 %not25 = icmp eq ptr %30, null br i1 %not25, label %if.then26, label %if.exit27 if.then26: ; preds = %if.then16 - store i64 ptrtoint (ptr @"test_ReadError$OUT_OF_MEMORY" to i64), ptr %error_var22, align 8 + store i64 ptrtoint (ptr @"test.ReadError$OUT_OF_MEMORY" to i64), ptr %error_var22, align 8 br label %guard_block28 if.exit27: ; preds = %if.then16 @@ -396,14 +396,14 @@ noerr_block29: ; preds = %if.exit27 %33 = load ptr, ptr %temp24, align 8 store ptr %33, ptr %28, align 8 call void @llvm.memcpy.p0.p0.i32(ptr align 8 %value20, ptr align 8 %literal21, i32 8, i1 false) - %34 = call ptr @std_core_mem_malloc(i64 8) #3 + %34 = call ptr @std_core_mem.malloc(i64 8) #3 store ptr %34, ptr %temp30, align 8 %35 = load ptr, ptr %temp30, align 8 %not31 = icmp eq ptr %35, null br i1 %not31, label %if.then32, label %if.exit33 if.then32: ; preds = %noerr_block29 - store i64 ptrtoint (ptr @"test_ReadError$OUT_OF_MEMORY" to i64), ptr %error_var19, align 8 + store i64 ptrtoint (ptr @"test.ReadError$OUT_OF_MEMORY" to i64), ptr %error_var19, align 8 br label %guard_block34 if.exit33: ; preds = %noerr_block29 @@ -432,14 +432,14 @@ if.exit36: ; preds = %if.exit13 %44 = load i32, ptr %len, align 4 %siuiext = sext i32 %44 to i64 %add = add i64 %siuiext, 1 - %45 = call ptr @std_core_mem_malloc(i64 %add) #3 + %45 = call ptr @std_core_mem.malloc(i64 %add) #3 store ptr %45, ptr %str, align 8 %46 = load ptr, ptr %str, align 8 %not37 = icmp eq ptr %46, null br i1 %not37, label %if.then38, label %if.exit39 if.then38: ; preds = %if.exit36 - ret i64 ptrtoint (ptr @"test_ReadError$OUT_OF_MEMORY" to i64) + ret i64 ptrtoint (ptr @"test.ReadError$OUT_OF_MEMORY" to i64) if.exit39: ; preds = %if.exit36 %47 = load ptr, ptr %str, align 8 @@ -465,14 +465,14 @@ if.exit39: ; preds = %if.exit36 %59 = insertvalue %"char[]" undef, ptr %ptroffset50, 0 %60 = insertvalue %"char[]" %59, i64 %size, 1 store %"char[]" %60, ptr %value49, align 8 - %61 = call ptr @std_core_mem_malloc(i64 16) #3 + %61 = call ptr @std_core_mem.malloc(i64 16) #3 store ptr %61, ptr %temp51, align 8 %62 = load ptr, ptr %temp51, align 8 %not52 = icmp eq ptr %62, null br i1 %not52, label %if.then53, label %if.exit54 if.then53: ; preds = %if.exit39 - store i64 ptrtoint (ptr @"test_ReadError$OUT_OF_MEMORY" to i64), ptr %error_var48, align 8 + store i64 ptrtoint (ptr @"test.ReadError$OUT_OF_MEMORY" to i64), ptr %error_var48, align 8 br label %guard_block55 if.exit54: ; preds = %if.exit39 @@ -488,14 +488,14 @@ noerr_block56: ; preds = %if.exit54 %65 = load ptr, ptr %temp51, align 8 store ptr %65, ptr %55, align 8 call void @llvm.memcpy.p0.p0.i32(ptr align 8 %value46, ptr align 8 %literal47, i32 8, i1 false) - %66 = call ptr @std_core_mem_malloc(i64 8) #3 + %66 = call ptr @std_core_mem.malloc(i64 8) #3 store ptr %66, ptr %temp57, align 8 %67 = load ptr, ptr %temp57, align 8 %not58 = icmp eq ptr %67, null br i1 %not58, label %if.then59, label %if.exit60 if.then59: ; preds = %noerr_block56 - store i64 ptrtoint (ptr @"test_ReadError$OUT_OF_MEMORY" to i64), ptr %error_var45, align 8 + store i64 ptrtoint (ptr @"test.ReadError$OUT_OF_MEMORY" to i64), ptr %error_var45, align 8 br label %guard_block61 if.exit60: ; preds = %noerr_block56 @@ -515,7 +515,7 @@ noerr_block62: ; preds = %if.exit60 } ; Function Attrs: nounwind -define { ptr, i8 } @test_buildSummary(ptr %0) #0 { +define { ptr, i8 } @test.buildSummary(ptr %0) #0 { entry: %doc = alloca %Doc, align 8 %literal = alloca %Summary, align 8 @@ -550,7 +550,7 @@ cond.phi: ; preds = %cond.rhs, %cond.lhs } ; Function Attrs: nounwind -define { ptr, i8 } @test_readAndBuildSummary(ptr %0, i64 %1) #0 { +define { ptr, i8 } @test.readAndBuildSummary(ptr %0, i64 %1) #0 { entry: %url = alloca %"char[]", align 8 %retparam = alloca %Doc, align 8 @@ -564,14 +564,14 @@ entry: %lo = load ptr, ptr %2, align 8 %3 = getelementptr inbounds %"char[]", ptr %url, i32 0, i32 1 %hi = load i64, ptr %3, align 8 - %4 = call i64 @test_readDoc(ptr %retparam, ptr %lo, i64 %hi) + %4 = call i64 @test.readDoc(ptr %retparam, ptr %lo, i64 %hi) %not_err = icmp eq i64 %4, 0 %5 = call i1 @llvm.expect.i1(i1 %not_err, i1 true) br i1 %5, label %after_check, label %else_block after_check: ; preds = %entry %6 = load ptr, ptr %retparam, align 8 - %7 = call { ptr, i8 } @test_buildSummary(ptr %6) + %7 = call { ptr, i8 } @test.buildSummary(ptr %6) store { ptr, i8 } %7, ptr %result, align 8 %8 = load %Summary, ptr %result, align 8 br label %phi_block @@ -592,7 +592,7 @@ phi_block: ; preds = %else_block, %after_ } ; Function Attrs: nounwind -define i64 @test_isTitleNonEmpty(ptr %0, ptr %1) #0 { +define i64 @test.isTitleNonEmpty(ptr %0, ptr %1) #0 { entry: %doc = alloca %Doc, align 8 %head = alloca ptr, align 8 @@ -604,7 +604,7 @@ entry: br i1 %not, label %if.then, label %if.exit if.then: ; preds = %entry - ret i64 ptrtoint (ptr @"test_TitleResult$TITLE_MISSING" to i64) + ret i64 ptrtoint (ptr @"test.TitleResult$TITLE_MISSING" to i64) if.exit: ; preds = %entry %4 = getelementptr inbounds %Doc, ptr %doc, i32 0, i32 0 @@ -617,7 +617,7 @@ if.exit: ; preds = %entry br i1 %not1, label %if.then2, label %if.exit3 if.then2: ; preds = %if.exit - ret i64 ptrtoint (ptr @"test_TitleResult$TITLE_MISSING" to i64) + ret i64 ptrtoint (ptr @"test.TitleResult$TITLE_MISSING" to i64) if.exit3: ; preds = %if.exit %9 = load ptr, ptr %head, align 8 @@ -630,7 +630,7 @@ if.exit3: ; preds = %if.exit } ; Function Attrs: nounwind -define i64 @test_readWhetherTitleNonEmpty(ptr %0, ptr %1, i64 %2) #0 { +define i64 @test.readWhetherTitleNonEmpty(ptr %0, ptr %1, i64 %2) #0 { entry: %url = alloca %"char[]", align 8 %reterr = alloca i64, align 8 @@ -643,7 +643,7 @@ entry: %lo = load ptr, ptr %3, align 8 %4 = getelementptr inbounds %"char[]", ptr %url, i32 0, i32 1 %hi = load i64, ptr %4, align 8 - %5 = call i64 @test_readDoc(ptr %retparam1, ptr %lo, i64 %hi) + %5 = call i64 @test.readDoc(ptr %retparam1, ptr %lo, i64 %hi) %not_err = icmp eq i64 %5, 0 %6 = call i1 @llvm.expect.i1(i1 %not_err, i1 true) br i1 %6, label %after_check, label %assign_optional @@ -654,7 +654,7 @@ assign_optional: ; preds = %entry after_check: ; preds = %entry %7 = load ptr, ptr %retparam1, align 8 - %8 = call i64 @test_isTitleNonEmpty(ptr %retparam, ptr %7) + %8 = call i64 @test.isTitleNonEmpty(ptr %retparam, ptr %7) %not_err2 = icmp eq i64 %8, 0 %9 = call i1 @llvm.expect.i1(i1 %not_err2, i1 true) br i1 %9, label %after_check4, label %assign_optional3 @@ -674,7 +674,7 @@ err_retblock: ; preds = %assign_optional3, % } ; Function Attrs: nounwind -define ptr @test_bool_to_string(i8 zeroext %0) #0 { +define ptr @test.bool_to_string(i8 zeroext %0) #0 { entry: %1 = trunc i8 %0 to i1 %ternary = select i1 %1, %"char[]" { ptr @.str.9, i64 4 }, %"char[]" { ptr @.str.10, i64 5 } @@ -683,7 +683,7 @@ entry: } ; Function Attrs: nounwind -define ptr @test_nameFromError(i64 %0) #0 { +define ptr @test.nameFromError(i64 %0) #0 { entry: %switch = alloca i64, align 8 store i64 %0, ptr %switch, align 8 @@ -691,21 +691,21 @@ entry: switch.entry: ; preds = %entry %1 = load i64, ptr %switch, align 8 - %eq = icmp eq i64 ptrtoint (ptr @"test_TitleResult$TITLE_MISSING" to i64), %1 + %eq = icmp eq i64 ptrtoint (ptr @"test.TitleResult$TITLE_MISSING" to i64), %1 br i1 %eq, label %switch.case, label %next_if switch.case: ; preds = %switch.entry ret ptr @.str.11 next_if: ; preds = %switch.entry - %eq1 = icmp eq i64 ptrtoint (ptr @"test_ReadError$BAD_READ" to i64), %1 + %eq1 = icmp eq i64 ptrtoint (ptr @"test.ReadError$BAD_READ" to i64), %1 br i1 %eq1, label %switch.case2, label %next_if3 switch.case2: ; preds = %next_if ret ptr @.str.12 next_if3: ; preds = %next_if - %eq4 = icmp eq i64 ptrtoint (ptr @"test_ReadError$OUT_OF_MEMORY" to i64), %1 + %eq4 = icmp eq i64 ptrtoint (ptr @"test.ReadError$OUT_OF_MEMORY" to i64), %1 br i1 %eq4, label %switch.case5, label %next_if6 switch.case5: ; preds = %next_if3 @@ -719,7 +719,7 @@ switch.default: ; preds = %next_if6 } ; Function Attrs: nounwind -define void @test_main() #0 { +define void @test.main() #0 { entry: %URLS = alloca %"char[][]", align 8 %literal = alloca [5 x %"char[]"], align 16 @@ -773,12 +773,12 @@ loop.body: ; preds = %loop.cond %lo = load ptr, ptr %19, align 8 %20 = getelementptr inbounds %"char[]", ptr %url, i32 0, i32 1 %hi = load i64, ptr %20, align 8 - %21 = call { ptr, i8 } @test_readAndBuildSummary(ptr %lo, i64 %hi) + %21 = call { ptr, i8 } @test.readAndBuildSummary(ptr %lo, i64 %hi) store { ptr, i8 } %21, ptr %result, align 8 call void @llvm.memcpy.p0.p0.i32(ptr align 8 %summary, ptr align 8 %result, i32 16, i1 false) %22 = call i32 (ptr, ...) @printf(ptr @.str.21) %23 = load ptr, ptr @__stdoutp, align 8 - call void @test_Summary_print(ptr %summary, ptr %23) + call void @test.Summary_print(ptr %summary, ptr %23) %24 = call i32 (ptr, ...) @printf(ptr @.str.22) %25 = getelementptr inbounds %Summary, ptr %summary, i32 0, i32 0 %26 = load ptr, ptr %25, align 8 @@ -807,7 +807,7 @@ cond.phi: ; preds = %cond.rhs, %cond.lhs %lo3 = load ptr, ptr %35, align 8 %36 = getelementptr inbounds %"char[]", ptr %url, i32 0, i32 1 %hi4 = load i64, ptr %36, align 8 - %37 = call i64 @test_readWhetherTitleNonEmpty(ptr %retparam, ptr %lo3, i64 %hi4) + %37 = call i64 @test.readWhetherTitleNonEmpty(ptr %retparam, ptr %lo3, i64 %hi4) %not_err = icmp eq i64 %37, 0 %38 = call i1 @llvm.expect.i1(i1 %not_err, i1 true) br i1 %38, label %after_check, label %assign_optional @@ -830,12 +830,12 @@ after_assign: ; preds = %after_check, %assig after_check6: ; preds = %after_assign %41 = load i8, ptr %has_title, align 1 - %42 = call ptr @test_bool_to_string(i8 zeroext %41) + %42 = call ptr @test.bool_to_string(i8 zeroext %41) br label %phi_block else_block: ; preds = %after_assign %43 = load i64, ptr %has_title.f, align 8 - %44 = call ptr @test_nameFromError(i64 %43) + %44 = call ptr @test.nameFromError(i64 %43) br label %phi_block phi_block: ; preds = %else_block, %after_check6 diff --git a/test/test_suite/errors/failable_catch.c3t b/test/test_suite/errors/failable_catch.c3t index c4edb1f8a..a9d447afe 100644 --- a/test/test_suite/errors/failable_catch.c3t +++ b/test/test_suite/errors/failable_catch.c3t @@ -55,7 +55,7 @@ if.then: ; preds = %entry br label %expr_block.exit if.exit: ; preds = %entry - store i64 ptrtoint (ptr @"failable_catch_MyErr$TEST" to i64), ptr %a.f, align 8 + store i64 ptrtoint (ptr @"failable_catch.MyErr$TEST" to i64), ptr %a.f, align 8 br label %after_assign expr_block.exit: ; preds = %if.then @@ -91,7 +91,7 @@ if.then4: ; preds = %phi_block br label %expr_block.exit6 if.exit5: ; preds = %phi_block - store i64 ptrtoint (ptr @"failable_catch_MyErr$TEST" to i64), ptr %b.f, align 8 + store i64 ptrtoint (ptr @"failable_catch.MyErr$TEST" to i64), ptr %b.f, align 8 br label %after_assign7 expr_block.exit6: ; preds = %if.then4 @@ -112,7 +112,7 @@ if.then11: ; preds = %after_assign7 br label %expr_block.exit13 if.exit12: ; preds = %after_assign7 - store i64 ptrtoint (ptr @"failable_catch_MyErr$TEST" to i64), ptr %c.f, align 8 + store i64 ptrtoint (ptr @"failable_catch.MyErr$TEST" to i64), ptr %c.f, align 8 br label %after_assign14 expr_block.exit13: ; preds = %if.then11 diff --git a/test/test_suite/errors/general_error_regression.c3t b/test/test_suite/errors/general_error_regression.c3t index e72a6b694..19d295633 100644 --- a/test/test_suite/errors/general_error_regression.c3t +++ b/test/test_suite/errors/general_error_regression.c3t @@ -72,46 +72,46 @@ fn void main() /* #expect: foo.ll -define void @foo_Foo_hello(ptr %0) #0 { +define void @foo.Foo_hello(ptr %0) #0 { entry: %x = alloca ptr, align 8 %retparam = alloca i64, align 8 %result = alloca %File, align 8 store ptr @.str.12, ptr %x, align 8 - %1 = call ptr @std_io_stdout() + %1 = call ptr @std_io.stdout() store ptr %1, ptr %result, align 8 %2 = load ptr, ptr %x, align 8 - %3 = call i64 @std_io_File_printn(ptr %retparam, ptr %result, ptr %2, i64 14) + %3 = call i64 @std_io.File_printn(ptr %retparam, ptr %result, ptr %2, i64 14) ret void } -define void @foo_Bar_hello(ptr %0) #0 { +define void @foo.Bar_hello(ptr %0) #0 { entry: %x = alloca ptr, align 8 %retparam = alloca i64, align 8 %result = alloca %File, align 8 store ptr @.str.13, ptr %x, align 8 - %1 = call ptr @std_io_stdout() + %1 = call ptr @std_io.stdout() store ptr %1, ptr %result, align 8 %2 = load ptr, ptr %x, align 8 - %3 = call i64 @std_io_File_printn(ptr %retparam, ptr %result, ptr %2, i64 14) + %3 = call i64 @std_io.File_printn(ptr %retparam, ptr %result, ptr %2, i64 14) ret void } -define void @foo_MyEnum_hello(ptr %0) #0 { +define void @foo.MyEnum_hello(ptr %0) #0 { entry: %x = alloca ptr, align 8 %retparam = alloca i64, align 8 %result = alloca %File, align 8 store ptr @.str.14, ptr %x, align 8 - %1 = call ptr @std_io_stdout() + %1 = call ptr @std_io.stdout() store ptr %1, ptr %result, align 8 %2 = load ptr, ptr %x, align 8 - %3 = call i64 @std_io_File_printn(ptr %retparam, ptr %result, ptr %2, i64 17) + %3 = call i64 @std_io.File_printn(ptr %retparam, ptr %result, ptr %2, i64 17) ret void } -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %f = alloca i64, align 8 %ef = alloca i64, align 8 @@ -119,8 +119,8 @@ entry: %z = alloca i64, align 8 %b = alloca i32, align 4 %a = alloca i32, align 4 - store i64 ptrtoint (ptr @"foo_Foo$X" to i64), ptr %f, align 8 - store i64 ptrtoint (ptr @"foo_Foo$Y" to i64), ptr %ef, align 8 + store i64 ptrtoint (ptr @"foo.Foo$X" to i64), ptr %f, align 8 + store i64 ptrtoint (ptr @"foo.Foo$Y" to i64), ptr %ef, align 8 %0 = load i64, ptr %f, align 8 store i64 %0, ptr %x, align 8 %1 = load i64, ptr %x, align 8 @@ -133,30 +133,30 @@ entry: store i64 %5, ptr %z, align 8 %6 = load i64, ptr %z, align 8 %7 = call i32 (ptr, ...) @printf(ptr @.str.7, i64 %6) - store i64 ptrtoint (ptr @"foo_Foo$W" to i64), ptr %x, align 8 + store i64 ptrtoint (ptr @"foo.Foo$W" to i64), ptr %x, align 8 %8 = load i64, ptr %x, align 8 store i64 %8, ptr %z, align 8 %9 = load i64, ptr %z, align 8 %10 = call i32 (ptr, ...) @printf(ptr @.str.8, i64 %9) - store i64 ptrtoint (ptr @"foo_Foo$W1" to i64), ptr %x, align 8 + store i64 ptrtoint (ptr @"foo.Foo$W1" to i64), ptr %x, align 8 %11 = load i64, ptr %x, align 8 store i64 %11, ptr %z, align 8 %12 = load i64, ptr %z, align 8 %13 = call i32 (ptr, ...) @printf(ptr @.str.9, i64 %12) - store i64 ptrtoint (ptr @"foo_Foob$X1" to i64), ptr %x, align 8 + store i64 ptrtoint (ptr @"foo.Foob$X1" to i64), ptr %x, align 8 %14 = load i64, ptr %x, align 8 store i64 %14, ptr %z, align 8 %15 = load i64, ptr %z, align 8 %16 = call i32 (ptr, ...) @printf(ptr @.str.10, i64 %15) - store i64 ptrtoint (ptr @"foo_Foob$Y2" to i64), ptr %x, align 8 + store i64 ptrtoint (ptr @"foo.Foob$Y2" to i64), ptr %x, align 8 %17 = load i64, ptr %x, align 8 store i64 %17, ptr %z, align 8 %18 = load i64, ptr %z, align 8 %19 = call i32 (ptr, ...) @printf(ptr @.str.11, i64 %18) store i32 0, ptr %b, align 4 store i32 0, ptr %a, align 4 - call void @foo_Foo_hello(ptr %f) - call void @foo_Bar_hello(ptr %b) - call void @foo_MyEnum_hello(ptr %a) + call void @foo.Foo_hello(ptr %f) + call void @foo.Bar_hello(ptr %b) + call void @foo.MyEnum_hello(ptr %a) ret void } \ No newline at end of file diff --git a/test/test_suite/errors/macro_err.c3t b/test/test_suite/errors/macro_err.c3t index 29f15d0cf..d019063aa 100644 --- a/test/test_suite/errors/macro_err.c3t +++ b/test/test_suite/errors/macro_err.c3t @@ -18,7 +18,7 @@ fn void main() /* #expect: test.ll -define i64 @test_abc(ptr %0) #0 { +define i64 @test.abc(ptr %0) #0 { entry: %reterr = alloca i64, align 8 store i32 1, ptr %0, align 4 @@ -26,11 +26,11 @@ entry: } ; Function Attrs: nounwind -define void @test_main() #0 { +define void @test.main() #0 { entry: %error_var = alloca i64, align 8 %retparam = alloca i32, align 4 - %0 = call i64 @test_abc(ptr %retparam) + %0 = call i64 @test.abc(ptr %retparam) %not_err = icmp eq i64 %0, 0 %1 = call i1 @llvm.expect.i1(i1 %not_err, i1 true) br i1 %1, label %after_check, label %assign_optional diff --git a/test/test_suite/errors/macro_err2.c3t b/test/test_suite/errors/macro_err2.c3t index 5ae3e1b23..67ea309fe 100644 --- a/test/test_suite/errors/macro_err2.c3t +++ b/test/test_suite/errors/macro_err2.c3t @@ -21,16 +21,16 @@ fn void main() /* #expect: test.ll -define i64 @test_abc(ptr %0) #0 { +define i64 @test.abc(ptr %0) #0 { entry: - ret i64 ptrtoint (ptr @"test_Tester$FOO" to i64) + ret i64 ptrtoint (ptr @"test.Tester$FOO" to i64) } -define void @test_main() #0 { +define void @test.main() #0 { entry: %blockret = alloca i32, align 4 %retparam = alloca i32, align 4 - %0 = call i64 @test_abc(ptr %retparam) + %0 = call i64 @test.abc(ptr %retparam) %not_err = icmp eq i64 %0, 0 %1 = call i1 @llvm.expect.i1(i1 %not_err, i1 true) br i1 %1, label %after_check, label %opt_block_cleanup diff --git a/test/test_suite/errors/macro_err3.c3t b/test/test_suite/errors/macro_err3.c3t index 1e743a38e..6b6b045ea 100644 --- a/test/test_suite/errors/macro_err3.c3t +++ b/test/test_suite/errors/macro_err3.c3t @@ -18,7 +18,7 @@ fn void main() /* #expect: test.ll -define void @test_main() #0 { +define void @test.main() #0 { entry: %blockret = alloca i32, align 4 br label %opt_block_cleanup diff --git a/test/test_suite/errors/optional_chained_init.c3t b/test/test_suite/errors/optional_chained_init.c3t index 5b11d4ddd..790319e40 100644 --- a/test/test_suite/errors/optional_chained_init.c3t +++ b/test/test_suite/errors/optional_chained_init.c3t @@ -46,7 +46,7 @@ fn void main() /* #expect: test.ll -define void @test_test1() #0 { +define void @test.test1() #0 { entry: %a = alloca i32, align 4 %a.f = alloca i64, align 8 @@ -64,8 +64,8 @@ entry: %varargslots25 = alloca [1 x %variant], align 16 store i32 1, ptr %a, align 4 store i64 0, ptr %a.f, align 8 - store i64 ptrtoint (ptr @"test_Test$FOO" to i64), ptr %a.f, align 8 - store i64 ptrtoint (ptr @"test_Test$FOO" to i64), ptr %b.f, align 8 + store i64 ptrtoint (ptr @"test.Test$FOO" to i64), ptr %a.f, align 8 + store i64 ptrtoint (ptr @"test.Test$FOO" to i64), ptr %b.f, align 8 br label %after_assign after_assign: ; preds = %entry @@ -95,7 +95,7 @@ if.then: ; preds = %end_block %3 = insertvalue %variant %2, i64 ptrtoint (ptr @"ct$anyerr" to i64), 1 %4 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %3, ptr %4, align 16 - %5 = call i64 @std_io_printfn(ptr %retparam, ptr @.str, i64 13, ptr %varargslots, i64 1) + %5 = call i64 @std_io.printfn(ptr %retparam, ptr @.str, i64 13, ptr %varargslots, i64 1) br label %if.exit if.exit: ; preds = %if.then, %end_block @@ -125,7 +125,7 @@ if.then11: ; preds = %end_block9 %9 = insertvalue %variant %8, i64 ptrtoint (ptr @"ct$anyerr" to i64), 1 %10 = getelementptr inbounds [1 x %variant], ptr %varargslots13, i64 0, i64 0 store %variant %9, ptr %10, align 16 - %11 = call i64 @std_io_printfn(ptr %retparam12, ptr @.str.1, i64 13, ptr %varargslots13, i64 1) + %11 = call i64 @std_io.printfn(ptr %retparam12, ptr @.str.1, i64 13, ptr %varargslots13, i64 1) br label %if.exit16 if.exit16: ; preds = %if.then11, %end_block9 @@ -139,7 +139,7 @@ after_check21: ; preds = %if.exit16 %14 = insertvalue %variant %13, i64 ptrtoint (ptr @"ct$int" to i64), 1 %15 = getelementptr inbounds [1 x %variant], ptr %varargslots18, i64 0, i64 0 store %variant %14, ptr %15, align 16 - %16 = call i64 @std_io_printfn(ptr %retparam17, ptr @.str.2, i64 9, ptr %varargslots18, i64 1) + %16 = call i64 @std_io.printfn(ptr %retparam17, ptr @.str.2, i64 9, ptr %varargslots18, i64 1) %not_err22 = icmp eq i64 %16, 0 %17 = call i1 @llvm.expect.i1(i1 %not_err22, i1 true) br i1 %17, label %after_check23, label %after_check23 @@ -155,7 +155,7 @@ after_check28: ; preds = %after_check23 %20 = insertvalue %variant %19, i64 ptrtoint (ptr @"ct$int" to i64), 1 %21 = getelementptr inbounds [1 x %variant], ptr %varargslots25, i64 0, i64 0 store %variant %20, ptr %21, align 16 - %22 = call i64 @std_io_printfn(ptr %retparam24, ptr @.str.3, i64 9, ptr %varargslots25, i64 1) + %22 = call i64 @std_io.printfn(ptr %retparam24, ptr @.str.3, i64 9, ptr %varargslots25, i64 1) %not_err29 = icmp eq i64 %22, 0 %23 = call i1 @llvm.expect.i1(i1 %not_err29, i1 true) br i1 %23, label %after_check30, label %after_check30 @@ -165,7 +165,7 @@ after_check30: ; preds = %after_check23, %aft } ; Function Attrs: nounwind -define void @test_test2() #0 { +define void @test.test2() #0 { entry: %x = alloca i32, align 4 %x.f = alloca i64, align 8 @@ -183,7 +183,7 @@ entry: %varargslots23 = alloca [1 x %variant], align 16 %retparam29 = alloca i64, align 8 %varargslots30 = alloca [1 x %variant], align 16 - store i64 ptrtoint (ptr @"test_Test$FOO" to i64), ptr %x.f, align 8 + store i64 ptrtoint (ptr @"test.Test$FOO" to i64), ptr %x.f, align 8 store i32 1, ptr %a, align 4 store i64 0, ptr %a.f, align 8 %optval = load i64, ptr %x.f, align 8 @@ -238,7 +238,7 @@ if.then: ; preds = %end_block %5 = insertvalue %variant %4, i64 ptrtoint (ptr @"ct$anyerr" to i64), 1 %6 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %5, ptr %6, align 16 - %7 = call i64 @std_io_printfn(ptr %retparam, ptr @.str.4, i64 13, ptr %varargslots, i64 1) + %7 = call i64 @std_io.printfn(ptr %retparam, ptr @.str.4, i64 13, ptr %varargslots, i64 1) br label %if.exit if.exit: ; preds = %if.then, %end_block @@ -268,7 +268,7 @@ if.then16: ; preds = %end_block14 %11 = insertvalue %variant %10, i64 ptrtoint (ptr @"ct$anyerr" to i64), 1 %12 = getelementptr inbounds [1 x %variant], ptr %varargslots18, i64 0, i64 0 store %variant %11, ptr %12, align 16 - %13 = call i64 @std_io_printfn(ptr %retparam17, ptr @.str.5, i64 13, ptr %varargslots18, i64 1) + %13 = call i64 @std_io.printfn(ptr %retparam17, ptr @.str.5, i64 13, ptr %varargslots18, i64 1) br label %if.exit21 if.exit21: ; preds = %if.then16, %end_block14 @@ -282,7 +282,7 @@ after_check26: ; preds = %if.exit21 %16 = insertvalue %variant %15, i64 ptrtoint (ptr @"ct$int" to i64), 1 %17 = getelementptr inbounds [1 x %variant], ptr %varargslots23, i64 0, i64 0 store %variant %16, ptr %17, align 16 - %18 = call i64 @std_io_printfn(ptr %retparam22, ptr @.str.6, i64 9, ptr %varargslots23, i64 1) + %18 = call i64 @std_io.printfn(ptr %retparam22, ptr @.str.6, i64 9, ptr %varargslots23, i64 1) %not_err27 = icmp eq i64 %18, 0 %19 = call i1 @llvm.expect.i1(i1 %not_err27, i1 true) br i1 %19, label %after_check28, label %after_check28 @@ -298,7 +298,7 @@ after_check33: ; preds = %after_check28 %22 = insertvalue %variant %21, i64 ptrtoint (ptr @"ct$int" to i64), 1 %23 = getelementptr inbounds [1 x %variant], ptr %varargslots30, i64 0, i64 0 store %variant %22, ptr %23, align 16 - %24 = call i64 @std_io_printfn(ptr %retparam29, ptr @.str.7, i64 9, ptr %varargslots30, i64 1) + %24 = call i64 @std_io.printfn(ptr %retparam29, ptr @.str.7, i64 9, ptr %varargslots30, i64 1) %not_err34 = icmp eq i64 %24, 0 %25 = call i1 @llvm.expect.i1(i1 %not_err34, i1 true) br i1 %25, label %after_check35, label %after_check35 @@ -308,7 +308,7 @@ after_check35: ; preds = %after_check28, %aft } ; Function Attrs: nounwind -define void @test_test3() #0 { +define void @test.test3() #0 { entry: %x = alloca i32, align 4 %x.f = alloca i64, align 8 @@ -382,7 +382,7 @@ if.then: ; preds = %end_block %5 = insertvalue %variant %4, i64 ptrtoint (ptr @"ct$anyerr" to i64), 1 %6 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %5, ptr %6, align 16 - %7 = call i64 @std_io_printfn(ptr %retparam, ptr @.str.8, i64 13, ptr %varargslots, i64 1) + %7 = call i64 @std_io.printfn(ptr %retparam, ptr @.str.8, i64 13, ptr %varargslots, i64 1) br label %if.exit if.exit: ; preds = %if.then, %end_block @@ -412,7 +412,7 @@ if.then16: ; preds = %end_block14 %11 = insertvalue %variant %10, i64 ptrtoint (ptr @"ct$anyerr" to i64), 1 %12 = getelementptr inbounds [1 x %variant], ptr %varargslots18, i64 0, i64 0 store %variant %11, ptr %12, align 16 - %13 = call i64 @std_io_printfn(ptr %retparam17, ptr @.str.9, i64 13, ptr %varargslots18, i64 1) + %13 = call i64 @std_io.printfn(ptr %retparam17, ptr @.str.9, i64 13, ptr %varargslots18, i64 1) br label %if.exit21 if.exit21: ; preds = %if.then16, %end_block14 @@ -426,7 +426,7 @@ after_check26: ; preds = %if.exit21 %16 = insertvalue %variant %15, i64 ptrtoint (ptr @"ct$int" to i64), 1 %17 = getelementptr inbounds [1 x %variant], ptr %varargslots23, i64 0, i64 0 store %variant %16, ptr %17, align 16 - %18 = call i64 @std_io_printfn(ptr %retparam22, ptr @.str.10, i64 9, ptr %varargslots23, i64 1) + %18 = call i64 @std_io.printfn(ptr %retparam22, ptr @.str.10, i64 9, ptr %varargslots23, i64 1) %not_err27 = icmp eq i64 %18, 0 %19 = call i1 @llvm.expect.i1(i1 %not_err27, i1 true) br i1 %19, label %after_check28, label %after_check28 @@ -442,7 +442,7 @@ after_check33: ; preds = %after_check28 %22 = insertvalue %variant %21, i64 ptrtoint (ptr @"ct$int" to i64), 1 %23 = getelementptr inbounds [1 x %variant], ptr %varargslots30, i64 0, i64 0 store %variant %22, ptr %23, align 16 - %24 = call i64 @std_io_printfn(ptr %retparam29, ptr @.str.11, i64 9, ptr %varargslots30, i64 1) + %24 = call i64 @std_io.printfn(ptr %retparam29, ptr @.str.11, i64 9, ptr %varargslots30, i64 1) %not_err34 = icmp eq i64 %24, 0 %25 = call i1 @llvm.expect.i1(i1 %not_err34, i1 true) br i1 %25, label %after_check35, label %after_check35 diff --git a/test/test_suite/errors/optional_inits.c3t b/test/test_suite/errors/optional_inits.c3t index 51a20a6f9..50b1afbd3 100644 --- a/test/test_suite/errors/optional_inits.c3t +++ b/test/test_suite/errors/optional_inits.c3t @@ -33,14 +33,14 @@ fn void main() /* #expect: test.ll -define i64 @test_test1() #0 { +define i64 @test.test1() #0 { entry: %x = alloca %Bar, align 4 %x.f = alloca i64, align 8 %y = alloca %Bar, align 4 %error_var = alloca i64, align 8 %reterr = alloca i64, align 8 - store i64 ptrtoint (ptr @"test_Foo$MY_VAL1" to i64), ptr %x.f, align 8 + store i64 ptrtoint (ptr @"test.Foo$MY_VAL1" to i64), ptr %x.f, align 8 %optval = load i64, ptr %x.f, align 8 %not_err = icmp eq i64 %optval, 0 %0 = call i1 @llvm.expect.i1(i1 %not_err, i1 true) @@ -63,7 +63,7 @@ noerr_block: ; preds = %after_check } ; Function Attrs: nounwind -define i64 @test_test2() #0 { +define i64 @test.test2() #0 { entry: %x = alloca %Bar, align 4 %x.f = alloca i64, align 8 @@ -94,9 +94,9 @@ noerr_block: ; preds = %after_check } ; Function Attrs: nounwind -define void @test_main() #0 { +define void @test.main() #0 { entry: - %0 = call i64 @test_test1() - %1 = call i64 @test_test2() + %0 = call i64 @test.test1() + %1 = call i64 @test.test2() ret void } diff --git a/test/test_suite/errors/optional_taddr_and_access.c3t b/test/test_suite/errors/optional_taddr_and_access.c3t index dd817879b..36742611c 100644 --- a/test/test_suite/errors/optional_taddr_and_access.c3t +++ b/test/test_suite/errors/optional_taddr_and_access.c3t @@ -27,9 +27,9 @@ fn void main() %Foo = type { i32, i32 } -@"ct$test_Foo" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 -@"test_MyErr$FOO" = linkonce constant %.fault { i64 ptrtoint (ptr @"ct$test_MyErr" to i64), %"char[]" { ptr @.fault, i64 3 } }, align 8 -@"ct$test_MyErr" = linkonce constant %.introspect { i8 9, i64 8, i64 0, i64 1, [0 x i64] zeroinitializer }, align 8 +@"ct$test.Foo" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 +@"test.MyErr$FOO" = linkonce constant %.fault { i64 ptrtoint (ptr @"ct$test.MyErr" to i64), %"char[]" { ptr @.fault, i64 3 } }, align 8 +@"ct$test.MyErr" = linkonce constant %.introspect { i8 9, i64 8, i64 0, i64 1, [0 x i64] zeroinitializer }, align 8 @.str = private unnamed_addr constant [4 x i8] c"%d\0A\00", align 1 @.str.1 = private unnamed_addr constant [17 x i8] c"Not visible: %d\0A\00", align 1 @@ -37,7 +37,7 @@ fn void main() declare i32 @printf(ptr, ...) #0 ; Function Attrs: nounwind -define void @test_main() #0 { +define void @test.main() #0 { entry: %z = alloca i32, align 4 %z.f = alloca i64, align 8 @@ -80,7 +80,7 @@ after_check3: ; preds = %after_assign br label %voiderr voiderr: ; preds = %after_check3, %after_assign - store i64 ptrtoint (ptr @"test_MyErr$FOO" to i64), ptr %z.f, align 8 + store i64 ptrtoint (ptr @"test.MyErr$FOO" to i64), ptr %z.f, align 8 br label %after_check4 after_check4: ; preds = %voiderr diff --git a/test/test_suite/errors/optional_with_optional.c3t b/test/test_suite/errors/optional_with_optional.c3t index 15d3bd4a7..c7a75dd57 100644 --- a/test/test_suite/errors/optional_with_optional.c3t +++ b/test/test_suite/errors/optional_with_optional.c3t @@ -32,7 +32,7 @@ fn int! get_b(int x) /* #expect: test.ll -define void @test_main() #0 { +define void @test.main() #0 { entry: %retparam = alloca i64, align 8 %varargslots = alloca [1 x %variant], align 16 @@ -66,7 +66,7 @@ entry: %varargslots66 = alloca [1 x %variant], align 16 %xy = alloca i32, align 4 %xy.f = alloca i64, align 8 - %0 = call i64 @test_get_a(ptr %retparam1, i32 1) + %0 = call i64 @test.get_a(ptr %retparam1, i32 1) %not_err = icmp eq i64 %0, 0 %1 = call i1 @llvm.expect.i1(i1 %not_err, i1 true) br i1 %1, label %after_check, label %else_block @@ -76,7 +76,7 @@ after_check: ; preds = %entry br label %phi_block else_block: ; preds = %entry - %3 = call i64 @test_get_b(ptr %retparam2, i32 4) + %3 = call i64 @test.get_b(ptr %retparam2, i32 4) %not_err3 = icmp eq i64 %3, 0 %4 = call i1 @llvm.expect.i1(i1 %not_err3, i1 true) br i1 %4, label %after_check4, label %else_block5 @@ -99,8 +99,8 @@ phi_block6: ; preds = %else_block5, %phi_b %7 = insertvalue %variant %6, i64 ptrtoint (ptr @"ct$int" to i64), 1 %8 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %7, ptr %8, align 16 - %9 = call i64 @std_io_printfn(ptr %retparam, ptr @.str, i64 4, ptr %varargslots, i64 1) - %10 = call i64 @test_get_a(ptr %retparam12, i32 2) + %9 = call i64 @std_io.printfn(ptr %retparam, ptr @.str, i64 4, ptr %varargslots, i64 1) + %10 = call i64 @test.get_a(ptr %retparam12, i32 2) %not_err13 = icmp eq i64 %10, 0 %11 = call i1 @llvm.expect.i1(i1 %not_err13, i1 true) br i1 %11, label %after_check14, label %else_block15 @@ -110,7 +110,7 @@ after_check14: ; preds = %phi_block6 br label %phi_block19 else_block15: ; preds = %phi_block6 - %13 = call i64 @test_get_b(ptr %retparam16, i32 4) + %13 = call i64 @test.get_b(ptr %retparam16, i32 4) %not_err17 = icmp eq i64 %13, 0 %14 = call i1 @llvm.expect.i1(i1 %not_err17, i1 true) br i1 %14, label %after_check18, label %else_block21 @@ -133,8 +133,8 @@ phi_block22: ; preds = %else_block21, %phi_ %17 = insertvalue %variant %16, i64 ptrtoint (ptr @"ct$int" to i64), 1 %18 = getelementptr inbounds [1 x %variant], ptr %varargslots11, i64 0, i64 0 store %variant %17, ptr %18, align 16 - %19 = call i64 @std_io_printfn(ptr %retparam10, ptr @.str.2, i64 4, ptr %varargslots11, i64 1) - %20 = call i64 @test_get_a(ptr %retparam29, i32 1) + %19 = call i64 @std_io.printfn(ptr %retparam10, ptr @.str.2, i64 4, ptr %varargslots11, i64 1) + %20 = call i64 @test.get_a(ptr %retparam29, i32 1) %not_err30 = icmp eq i64 %20, 0 %21 = call i1 @llvm.expect.i1(i1 %not_err30, i1 true) br i1 %21, label %after_check31, label %else_block32 @@ -144,7 +144,7 @@ after_check31: ; preds = %phi_block22 br label %phi_block36 else_block32: ; preds = %phi_block22 - %23 = call i64 @test_get_b(ptr %retparam33, i32 5) + %23 = call i64 @test.get_b(ptr %retparam33, i32 5) %not_err34 = icmp eq i64 %23, 0 %24 = call i1 @llvm.expect.i1(i1 %not_err34, i1 true) br i1 %24, label %after_check35, label %else_block38 @@ -167,25 +167,25 @@ phi_block39: ; preds = %else_block38, %phi_ %27 = insertvalue %variant %26, i64 ptrtoint (ptr @"ct$int" to i64), 1 %28 = getelementptr inbounds [1 x %variant], ptr %varargslots28, i64 0, i64 0 store %variant %27, ptr %28, align 16 - %29 = call i64 @std_io_printfn(ptr %retparam27, ptr @.str.3, i64 4, ptr %varargslots28, i64 1) - store i64 ptrtoint (ptr @"test_Foo$DEF" to i64), ptr %taddr46, align 8 + %29 = call i64 @std_io.printfn(ptr %retparam27, ptr @.str.3, i64 4, ptr %varargslots28, i64 1) + store i64 ptrtoint (ptr @"test.Foo$DEF" to i64), ptr %taddr46, align 8 %30 = insertvalue %variant undef, ptr %taddr46, 0 %31 = insertvalue %variant %30, i64 ptrtoint (ptr @"ct$anyerr" to i64), 1 %32 = getelementptr inbounds [1 x %variant], ptr %varargslots45, i64 0, i64 0 store %variant %31, ptr %32, align 16 - %33 = call i64 @std_io_printfn(ptr %retparam44, ptr @.str.4, i64 4, ptr %varargslots45, i64 1) + %33 = call i64 @std_io.printfn(ptr %retparam44, ptr @.str.4, i64 4, ptr %varargslots45, i64 1) store i32 3, ptr %taddr51, align 4 %34 = insertvalue %variant undef, ptr %taddr51, 0 %35 = insertvalue %variant %34, i64 ptrtoint (ptr @"ct$int" to i64), 1 %36 = getelementptr inbounds [1 x %variant], ptr %varargslots50, i64 0, i64 0 store %variant %35, ptr %36, align 16 - %37 = call i64 @std_io_printfn(ptr %retparam49, ptr @.str.5, i64 4, ptr %varargslots50, i64 1) - store i64 ptrtoint (ptr @"test_Foo$DEF" to i64), ptr %taddr56, align 8 + %37 = call i64 @std_io.printfn(ptr %retparam49, ptr @.str.5, i64 4, ptr %varargslots50, i64 1) + store i64 ptrtoint (ptr @"test.Foo$DEF" to i64), ptr %taddr56, align 8 %38 = insertvalue %variant undef, ptr %taddr56, 0 %39 = insertvalue %variant %38, i64 ptrtoint (ptr @"ct$anyerr" to i64), 1 %40 = getelementptr inbounds [1 x %variant], ptr %varargslots55, i64 0, i64 0 store %variant %39, ptr %40, align 16 - %41 = call i64 @std_io_printfn(ptr %retparam54, ptr @.str.6, i64 4, ptr %varargslots55, i64 1) + %41 = call i64 @std_io.printfn(ptr %retparam54, ptr @.str.6, i64 4, ptr %varargslots55, i64 1) store i64 0, ptr %error_var, align 8 br label %phi_block62 @@ -197,19 +197,19 @@ noerr_block: ; preds = %phi_block62 %43 = insertvalue %variant %42, i64 ptrtoint (ptr @"ct$anyerr" to i64), 1 %44 = getelementptr inbounds [1 x %variant], ptr %varargslots60, i64 0, i64 0 store %variant %43, ptr %44, align 16 - %45 = call i64 @std_io_printfn(ptr %retparam59, ptr @.str.7, i64 4, ptr %varargslots60, i64 1) + %45 = call i64 @std_io.printfn(ptr %retparam59, ptr @.str.7, i64 4, ptr %varargslots60, i64 1) store i64 3, ptr %x, align 8 %46 = insertvalue %variant undef, ptr %x, 0 %47 = insertvalue %variant %46, i64 ptrtoint (ptr @"ct$long" to i64), 1 %48 = getelementptr inbounds [1 x %variant], ptr %varargslots66, i64 0, i64 0 store %variant %47, ptr %48, align 16 - %49 = call i64 @std_io_printfn(ptr %retparam65, ptr @.str.8, i64 4, ptr %varargslots66, i64 1) - store i64 ptrtoint (ptr @"test_Foo$DEF" to i64), ptr %xy.f, align 8 + %49 = call i64 @std_io.printfn(ptr %retparam65, ptr @.str.8, i64 4, ptr %varargslots66, i64 1) + store i64 ptrtoint (ptr @"test.Foo$DEF" to i64), ptr %xy.f, align 8 ret void } ; Function Attrs: nounwind -define i64 @test_get_a(ptr %0, i32 %1) #0 { +define i64 @test.get_a(ptr %0, i32 %1) #0 { entry: %reterr = alloca i64, align 8 %smod = srem i32 %1, 2 @@ -217,7 +217,7 @@ entry: br i1 %intbool, label %if.then, label %if.exit if.then: ; preds = %entry - ret i64 ptrtoint (ptr @"test_Foo$ABC" to i64) + ret i64 ptrtoint (ptr @"test.Foo$ABC" to i64) if.exit: ; preds = %entry %mul = mul i32 %1, 2 @@ -226,7 +226,7 @@ if.exit: ; preds = %entry } ; Function Attrs: nounwind -define i64 @test_get_b(ptr %0, i32 %1) #0 { +define i64 @test.get_b(ptr %0, i32 %1) #0 { entry: %reterr = alloca i64, align 8 %smod = srem i32 %1, 2 @@ -234,7 +234,7 @@ entry: br i1 %eq, label %if.then, label %if.exit if.then: ; preds = %entry - ret i64 ptrtoint (ptr @"test_Foo$ABC" to i64) + ret i64 ptrtoint (ptr @"test.Foo$ABC" to i64) if.exit: ; preds = %entry %mul = mul i32 %1, 2 diff --git a/test/test_suite/errors/or_and_rethrow.c3t b/test/test_suite/errors/or_and_rethrow.c3t index 7e38505f1..5b1a19dfc 100644 --- a/test/test_suite/errors/or_and_rethrow.c3t +++ b/test/test_suite/errors/or_and_rethrow.c3t @@ -39,7 +39,7 @@ fn void main() /* #expect: foo.ll -define i64 @foo_test(i32 %0) #0 { +define i64 @foo.test(i32 %0) #0 { entry: %retparam = alloca i64, align 8 %varargslots = alloca [1 x %variant], align 16 @@ -66,16 +66,16 @@ entry: %2 = insertvalue %variant %1, i64 ptrtoint (ptr @"ct$int" to i64), 1 %3 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %2, ptr %3, align 16 - %4 = call i64 @std_io_printfn(ptr %retparam, ptr @.str.1, i64 8, ptr %varargslots, i64 1) + %4 = call i64 @std_io.printfn(ptr %retparam, ptr @.str.1, i64 8, ptr %varargslots, i64 1) %intbool = icmp ne i32 %0, 0 br i1 %intbool, label %or.phi, label %or.rhs or.rhs: ; preds = %entry - store i64 ptrtoint (ptr @"foo_Foo$ABC" to i64), ptr %error_var, align 8 + store i64 ptrtoint (ptr @"foo.Foo$ABC" to i64), ptr %error_var, align 8 br label %opt_block_cleanup opt_block_cleanup: ; preds = %or.rhs - call void @foo_blurb() + call void @foo.blurb() br label %guard_block guard_block: ; preds = %opt_block_cleanup @@ -87,23 +87,23 @@ or.phi: ; preds = %entry if.then: ; preds = %or.phi store ptr @.str.2, ptr %x, align 8 - %6 = call ptr @std_io_stdout() + %6 = call ptr @std_io.stdout() store ptr %6, ptr %result, align 8 %7 = load ptr, ptr %x, align 8 - %8 = call i64 @std_io_File_printn(ptr %retparam1, ptr %result, ptr %7, i64 3) + %8 = call i64 @std_io.File_printn(ptr %retparam1, ptr %result, ptr %7, i64 3) br label %if.exit if.exit: ; preds = %if.then store ptr @.str.3, ptr %x2, align 8 - %9 = call ptr @std_io_stdout() + %9 = call ptr @std_io.stdout() store ptr %9, ptr %result4, align 8 %10 = load ptr, ptr %x2, align 8 - %11 = call i64 @std_io_File_printn(ptr %retparam3, ptr %result4, ptr %10, i64 9) - store i64 ptrtoint (ptr @"foo_Foo$ABC" to i64), ptr %error_var5, align 8 + %11 = call i64 @std_io.File_printn(ptr %retparam3, ptr %result4, ptr %10, i64 9) + store i64 ptrtoint (ptr @"foo.Foo$ABC" to i64), ptr %error_var5, align 8 br label %opt_block_cleanup7 opt_block_cleanup7: ; preds = %if.exit - call void @foo_blurb() + call void @foo.blurb() br label %guard_block8 guard_block8: ; preds = %opt_block_cleanup7 @@ -112,15 +112,15 @@ guard_block8: ; preds = %opt_block_cleanup7 if.exit13: ; No predecessors! store ptr @.str.5, ptr %x14, align 8 - %13 = call ptr @std_io_stdout() + %13 = call ptr @std_io.stdout() store ptr %13, ptr %result16, align 8 %14 = load ptr, ptr %x14, align 8 - %15 = call i64 @std_io_File_printn(ptr %retparam15, ptr %result16, ptr %14, i64 7) + %15 = call i64 @std_io.File_printn(ptr %retparam15, ptr %result16, ptr %14, i64 7) ret i64 0 } ; Function Attrs: nounwind -define i64 @foo_test2(i32 %0) #0 { +define i64 @foo.test2(i32 %0) #0 { entry: %retparam = alloca i64, align 8 %varargslots = alloca [1 x %variant], align 16 @@ -141,16 +141,16 @@ entry: %2 = insertvalue %variant %1, i64 ptrtoint (ptr @"ct$int" to i64), 1 %3 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %2, ptr %3, align 16 - %4 = call i64 @std_io_printfn(ptr %retparam, ptr @.str.6, i64 9, ptr %varargslots, i64 1) + %4 = call i64 @std_io.printfn(ptr %retparam, ptr @.str.6, i64 9, ptr %varargslots, i64 1) %intbool = icmp ne i32 %0, 0 br i1 %intbool, label %and.rhs, label %and.phi and.rhs: ; preds = %entry - store i64 ptrtoint (ptr @"foo_Foo$ABC" to i64), ptr %error_var, align 8 + store i64 ptrtoint (ptr @"foo.Foo$ABC" to i64), ptr %error_var, align 8 br label %opt_block_cleanup opt_block_cleanup: ; preds = %and.rhs - call void @foo_blurb() + call void @foo.blurb() br label %guard_block guard_block: ; preds = %opt_block_cleanup @@ -162,15 +162,15 @@ and.phi: ; preds = %entry if.exit: ; preds = %and.phi store ptr @.str.7, ptr %x, align 8 - %6 = call ptr @std_io_stdout() + %6 = call ptr @std_io.stdout() store ptr %6, ptr %result, align 8 %7 = load ptr, ptr %x, align 8 - %8 = call i64 @std_io_File_printn(ptr %retparam1, ptr %result, ptr %7, i64 9) - store i64 ptrtoint (ptr @"foo_Foo$ABC" to i64), ptr %error_var2, align 8 + %8 = call i64 @std_io.File_printn(ptr %retparam1, ptr %result, ptr %7, i64 9) + store i64 ptrtoint (ptr @"foo.Foo$ABC" to i64), ptr %error_var2, align 8 br label %opt_block_cleanup4 opt_block_cleanup4: ; preds = %if.exit - call void @foo_blurb() + call void @foo.blurb() br label %guard_block5 guard_block5: ; preds = %opt_block_cleanup4 @@ -179,15 +179,15 @@ guard_block5: ; preds = %opt_block_cleanup4 if.exit6: ; No predecessors! store ptr @.str.8, ptr %x7, align 8 - %10 = call ptr @std_io_stdout() + %10 = call ptr @std_io.stdout() store ptr %10, ptr %result9, align 8 %11 = load ptr, ptr %x7, align 8 - %12 = call i64 @std_io_File_printn(ptr %retparam8, ptr %result9, ptr %11, i64 7) + %12 = call i64 @std_io.File_printn(ptr %retparam8, ptr %result9, ptr %11, i64 7) ret i64 0 } ; Function Attrs: nounwind -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %a = alloca i64, align 8 %error_var = alloca i64, align 8 @@ -198,7 +198,7 @@ entry: %d = alloca i64, align 8 %error_var11 = alloca i64, align 8 store i64 0, ptr %error_var, align 8 - %0 = call i64 @foo_test(i32 0) + %0 = call i64 @foo.test(i32 0) %not_err = icmp eq i64 %0, 0 %1 = call i1 @llvm.expect.i1(i1 %not_err, i1 true) br i1 %1, label %after_check, label %assign_optional @@ -214,7 +214,7 @@ noerr_block: ; preds = %after_check, %assig %2 = load i64, ptr %error_var, align 8 store i64 %2, ptr %a, align 8 store i64 0, ptr %error_var1, align 8 - %3 = call i64 @foo_test(i32 1) + %3 = call i64 @foo.test(i32 1) %not_err2 = icmp eq i64 %3, 0 %4 = call i1 @llvm.expect.i1(i1 %not_err2, i1 true) br i1 %4, label %after_check4, label %assign_optional3 @@ -230,7 +230,7 @@ noerr_block5: ; preds = %after_check4, %assi %5 = load i64, ptr %error_var1, align 8 store i64 %5, ptr %b, align 8 store i64 0, ptr %error_var6, align 8 - %6 = call i64 @foo_test2(i32 0) + %6 = call i64 @foo.test2(i32 0) %not_err7 = icmp eq i64 %6, 0 %7 = call i1 @llvm.expect.i1(i1 %not_err7, i1 true) br i1 %7, label %after_check9, label %assign_optional8 @@ -246,7 +246,7 @@ noerr_block10: ; preds = %after_check9, %assi %8 = load i64, ptr %error_var6, align 8 store i64 %8, ptr %c, align 8 store i64 0, ptr %error_var11, align 8 - %9 = call i64 @foo_test2(i32 1) + %9 = call i64 @foo.test2(i32 1) %not_err12 = icmp eq i64 %9, 0 %10 = call i1 @llvm.expect.i1(i1 %not_err12, i1 true) br i1 %10, label %after_check14, label %assign_optional13 @@ -271,6 +271,6 @@ entry: %.anon1 = alloca ptr, align 8 store i32 %0, ptr %.anon, align 4 store ptr %1, ptr %.anon1, align 8 - call void @foo_main() + call void @foo.main() ret i32 0 } diff --git a/test/test_suite/errors/or_err_bool.c3t b/test/test_suite/errors/or_err_bool.c3t index f9411f98b..4a0b48e15 100644 --- a/test/test_suite/errors/or_err_bool.c3t +++ b/test/test_suite/errors/or_err_bool.c3t @@ -10,7 +10,7 @@ fn void tester() /* #expect: test.ll -define void @test_tester() #0 { +define void @test.tester() #0 { entry: %x = alloca i8, align 1 %x.f = alloca i64, align 8 diff --git a/test/test_suite/errors/printing_errors.c3t b/test/test_suite/errors/printing_errors.c3t index a2145a885..feaadb828 100644 --- a/test/test_suite/errors/printing_errors.c3t +++ b/test/test_suite/errors/printing_errors.c3t @@ -15,14 +15,14 @@ fn void main() /* #expect: test.ll -define void @test_main() #0 { +define void @test.main() #0 { entry: %x = alloca i64, align 8 %retparam = alloca i64, align 8 %varargslots = alloca [2 x %variant], align 16 %taddr = alloca ptr, align 8 %faultname_zero = alloca %"char[]", align 8 - store i64 ptrtoint (ptr @"test_Cde$WORLD" to i64), ptr %x, align 8 + store i64 ptrtoint (ptr @"test.Cde$WORLD" to i64), ptr %x, align 8 store ptr @.str.2, ptr %taddr, align 8 %0 = insertvalue %variant undef, ptr %taddr, 0 %1 = insertvalue %variant %0, i64 ptrtoint (ptr @"ct$p$a5$char" to i64), 1 @@ -47,6 +47,6 @@ faultname_exit: ; preds = %faultname_ok, %faul %7 = insertvalue %variant %6, i64 ptrtoint (ptr @"ct$sa$char" to i64), 1 %8 = getelementptr inbounds [2 x %variant], ptr %varargslots, i64 0, i64 1 store %variant %7, ptr %8, align 16 - %9 = call i64 @std_io_printf(ptr %retparam, ptr @.str, i64 6, ptr %varargslots, i64 2) + %9 = call i64 @std_io.printf(ptr %retparam, ptr @.str, i64 6, ptr %varargslots, i64 2) ret void } diff --git a/test/test_suite/errors/rethrow_mingw.c3t b/test/test_suite/errors/rethrow_mingw.c3t index 49959d2dc..31226389d 100644 --- a/test/test_suite/errors/rethrow_mingw.c3t +++ b/test/test_suite/errors/rethrow_mingw.c3t @@ -10,7 +10,7 @@ fn void! test() /* #expect: rethrow.ll -define i64 @rethrow_test() #0 { +define i64 @rethrow.test() #0 { entry: %i = alloca i32, align 4 %i.f = alloca i64, align 8 diff --git a/test/test_suite/errors/simple_static_failable.c3t b/test/test_suite/errors/simple_static_failable.c3t index 9e83c22bd..9465f1669 100644 --- a/test/test_suite/errors/simple_static_failable.c3t +++ b/test/test_suite/errors/simple_static_failable.c3t @@ -15,10 +15,10 @@ fn void main() /* #expect: foo.ll -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %i = alloca i32, align 4 %i.f = alloca i64, align 8 - store i64 ptrtoint (ptr @"foo_Blurg$Y" to i64), ptr %i.f, align 8 + store i64 ptrtoint (ptr @"foo.Blurg$Y" to i64), ptr %i.f, align 8 ret void } \ No newline at end of file diff --git a/test/test_suite/errors/try_assign.c3t b/test/test_suite/errors/try_assign.c3t index 558b31ed8..9770643a7 100644 --- a/test/test_suite/errors/try_assign.c3t +++ b/test/test_suite/errors/try_assign.c3t @@ -28,7 +28,7 @@ fn void main() /* #expect: try_assign.ll -define void @try_assign_main() #0 { +define void @try_assign.main() #0 { entry: %x = alloca i32, align 4 %z = alloca i32, align 4 diff --git a/test/test_suite/errors/try_catch_if.c3t b/test/test_suite/errors/try_catch_if.c3t index 3482abca1..f42a98b2f 100644 --- a/test/test_suite/errors/try_catch_if.c3t +++ b/test/test_suite/errors/try_catch_if.c3t @@ -37,7 +37,7 @@ fn void main() /* #expect: try_catch_if.ll -define i64 @try_catch_if_tester(ptr %0) #0 { +define i64 @try_catch_if.tester(ptr %0) #0 { entry: %reterr = alloca i64, align 8 %1 = call i32 (ptr, ...) @printf(ptr @.str) @@ -45,7 +45,7 @@ entry: ret i64 0 } -define void @try_catch_if_test1() #0 { +define void @try_catch_if.test1() #0 { entry: %a = alloca i32, align 4 %a.f = alloca i64, align 8 @@ -69,7 +69,7 @@ after_check: ; preds = %testblock br label %testblock1 testblock1: ; preds = %after_check - %1 = call i64 @try_catch_if_tester(ptr %retparam) + %1 = call i64 @try_catch_if.tester(ptr %retparam) %not_err2 = icmp eq i64 %1, 0 %2 = call i1 @llvm.expect.i1(i1 %not_err2, i1 true) br i1 %2, label %after_check4, label %assign_optional3 diff --git a/test/test_suite/errors/try_unwrap_using_assert.c3t b/test/test_suite/errors/try_unwrap_using_assert.c3t index 8b28abd97..25bee1abd 100644 --- a/test/test_suite/errors/try_unwrap_using_assert.c3t +++ b/test/test_suite/errors/try_unwrap_using_assert.c3t @@ -13,7 +13,7 @@ fn int tester(int n) /* #expect: test.ll -define i32 @test_tester(i32 %0) #0 { +define i32 @test.tester(i32 %0) #0 { entry: %num = alloca i32, align 4 %num.f = alloca i64, align 8 diff --git a/test/test_suite/errors/try_with_chained_unwrap.c3t b/test/test_suite/errors/try_with_chained_unwrap.c3t index 74dcc60bf..467ef4f58 100644 --- a/test/test_suite/errors/try_with_chained_unwrap.c3t +++ b/test/test_suite/errors/try_with_chained_unwrap.c3t @@ -19,7 +19,7 @@ fn void main() /* #expect: try_with_chained_unwrap.ll -define void @try_with_chained_unwrap_main() #0 { +define void @try_with_chained_unwrap.main() #0 { entry: %val = alloca i32, align 4 %retparam = alloca i32, align 4 diff --git a/test/test_suite/errors/try_with_unwrap.c3t b/test/test_suite/errors/try_with_unwrap.c3t index e34e55ff6..46379c269 100644 --- a/test/test_suite/errors/try_with_unwrap.c3t +++ b/test/test_suite/errors/try_with_unwrap.c3t @@ -21,7 +21,7 @@ fn void main() /* #expect: try_with_unwrap.ll -define void @try_with_unwrap_main() #0 { +define void @try_with_unwrap.main() #0 { entry: %line = alloca ptr, align 8 %line.f = alloca i64, align 8 diff --git a/test/test_suite/errors/try_with_unwrapper.c3t b/test/test_suite/errors/try_with_unwrapper.c3t index da1266927..8fd20f2e6 100644 --- a/test/test_suite/errors/try_with_unwrapper.c3t +++ b/test/test_suite/errors/try_with_unwrapper.c3t @@ -43,7 +43,7 @@ fn void test2() /* #expect: try_with_unwrapper.ll ; Function Attrs: nounwind -define i32 @try_with_unwrapper_hello(i32 %0) #0 { +define i32 @try_with_unwrapper.hello(i32 %0) #0 { entry: %add = add i32 %0, 1 ret i32 %add @@ -53,7 +53,7 @@ entry: declare i32 @printf(ptr, ...) #0 ; Function Attrs: nounwind -define i64 @try_with_unwrapper_tester(ptr %0) #0 { +define i64 @try_with_unwrapper.tester(ptr %0) #0 { entry: %reterr = alloca i64, align 8 %1 = call i32 (ptr, ...) @printf(ptr @.str) @@ -62,7 +62,7 @@ entry: } ; Function Attrs: nounwind -define void @try_with_unwrapper_test1() #0 { +define void @try_with_unwrapper.test1() #0 { entry: %a = alloca i32, align 4 %a.f = alloca i64, align 8 @@ -91,7 +91,7 @@ phi_try_catch: ; preds = %catch_landing, %aft chain_next: ; preds = %phi_try_catch store i32 0, ptr %c, align 4 - %2 = call i64 @try_with_unwrapper_tester(ptr %retparam) + %2 = call i64 @try_with_unwrapper.tester(ptr %retparam) %not_err1 = icmp eq i64 %2, 0 %3 = call i1 @llvm.expect.i1(i1 %not_err1, i1 true) br i1 %3, label %after_check2, label %catch_landing3 @@ -120,7 +120,7 @@ end_chain: ; preds = %fail_chain, %chain_ if.then: ; preds = %end_chain %5 = load i32, ptr %b, align 4 - %6 = call i32 @try_with_unwrapper_hello(i32 %5) + %6 = call i32 @try_with_unwrapper.hello(i32 %5) %7 = call i32 (ptr, ...) @printf(ptr @.str.1, i32 %6) %8 = load i32, ptr %c, align 4 %9 = call i32 (ptr, ...) @printf(ptr @.str.2, i32 %8) @@ -132,7 +132,7 @@ if.exit: ; preds = %if.then, %end_chain ; Function Attrs: nounwind -define void @try_with_unwrapper_test2() #0 { +define void @try_with_unwrapper.test2() #0 { entry: %a = alloca i32, align 4 %a.f = alloca i64, align 8 @@ -159,7 +159,7 @@ phi_try_catch: ; preds = %catch_landing, %aft chain_next: ; preds = %phi_try_catch %2 = load i32, ptr %b, align 4 - %3 = call i32 @try_with_unwrapper_hello(i32 %2) + %3 = call i32 @try_with_unwrapper.hello(i32 %2) %intbool = icmp ne i32 %3, 0 br i1 %intbool, label %chain_next1, label %fail_chain @@ -176,7 +176,7 @@ end_chain: ; preds = %fail_chain, %chain_ if.then: ; preds = %end_chain %4 = load i32, ptr %b, align 4 %add = add i32 %4, 1 - %5 = call i32 @try_with_unwrapper_hello(i32 %add) + %5 = call i32 @try_with_unwrapper.hello(i32 %add) br label %if.exit if.exit: ; preds = %if.then, %end_chain diff --git a/test/test_suite/expressions/addr_compiles.c3t b/test/test_suite/expressions/addr_compiles.c3t index 5d03a22c7..a89ea295a 100644 --- a/test/test_suite/expressions/addr_compiles.c3t +++ b/test/test_suite/expressions/addr_compiles.c3t @@ -49,16 +49,16 @@ fn void test3() /* #expect: test.ll -define void @test_main() #0 { +define void @test.main() #0 { entry: - call void @test_test() - call void @test_test2() - call void @test_test3() + call void @test.test() + call void @test.test2() + call void @test.test3() ret void } ; Function Attrs: nounwind -define void @test_test() #0 { +define void @test.test() #0 { entry: %f = alloca i32, align 4 %x = alloca ptr, align 8 @@ -80,10 +80,10 @@ entry: } ; Function Attrs: nounwind -define void @test_test2() #0 { +define void @test.test2() #0 { entry: %w = alloca ptr, align 8 - store ptr @test_XX, ptr %w, align 8 + store ptr @test.XX, ptr %w, align 8 %0 = load ptr, ptr %w, align 8 %1 = load i32, ptr %0, align 4 call void (ptr, ...) @printf(ptr @.str.1, i32 %1) @@ -91,7 +91,7 @@ entry: } ; Function Attrs: nounwind -define void @test_test3() #0 { +define void @test.test3() #0 { entry: %h = alloca %Foo, align 4 %zx = alloca ptr, align 8 diff --git a/test/test_suite/expressions/bool_conversions.c3t b/test/test_suite/expressions/bool_conversions.c3t index 47949ece6..67b32e3ee 100644 --- a/test/test_suite/expressions/bool_conversions.c3t +++ b/test/test_suite/expressions/bool_conversions.c3t @@ -10,22 +10,22 @@ fn bool f1() { return (bool){| Test x @noinit; return x = (Test)0; |}; } /* #expect: bool_conversions.ll -define internal zeroext i8 @bool_conversions_f0_0(ptr %0) #0 { +define internal zeroext i8 @bool_conversions.f0_0(ptr %0) #0 { entry: %ptrbool = icmp ne ptr %0, null %1 = zext i1 %ptrbool to i8 ret i8 %1 } -define i32 @bool_conversions_f0() #0 { +define i32 @bool_conversions.f0() #0 { entry: - %0 = call i8 @bool_conversions_f0_0(ptr inttoptr (i64 2 to ptr)) + %0 = call i8 @bool_conversions.f0_0(ptr inttoptr (i64 2 to ptr)) %1 = trunc i8 %0 to i1 %boolsi = zext i1 %1 to i32 ret i32 %boolsi } -define zeroext i8 @bool_conversions_f1() #0 { +define zeroext i8 @bool_conversions.f1() #0 { entry: %x = alloca ptr, align 8 store ptr null, ptr %x, align 8 diff --git a/test/test_suite/expressions/call_inline.c3t b/test/test_suite/expressions/call_inline.c3t index 11968f06a..887ca9f24 100644 --- a/test/test_suite/expressions/call_inline.c3t +++ b/test/test_suite/expressions/call_inline.c3t @@ -32,15 +32,15 @@ fn void main() // #expect: inlineme.ll entry: - call void @inlineme_test1() #3 - call void @inlineme_test2() #3 - call void @inlineme_test3() #3 - call void @inlineme_test1() #4 - call void @inlineme_test2() #4 - call void @inlineme_test3() #4 - call void @inlineme_test1() #3 - call void @inlineme_test2() - call void @inlineme_test3() + call void @inlineme.test1() #3 + call void @inlineme.test2() #3 + call void @inlineme.test3() #3 + call void @inlineme.test1() #4 + call void @inlineme.test2() #4 + call void @inlineme.test3() #4 + call void @inlineme.test1() #3 + call void @inlineme.test2() + call void @inlineme.test3() ret void } diff --git a/test/test_suite/expressions/casts/void_casting.c3 b/test/test_suite/expressions/casts/void_casting.c3 index 0cc7a309e..068d774fa 100644 --- a/test/test_suite/expressions/casts/void_casting.c3 +++ b/test/test_suite/expressions/casts/void_casting.c3 @@ -51,7 +51,7 @@ after_check: ; preds = %entry br label %end_block end_block: ; preds = %after_check, %entry - %2 = call i64 @test_foo() + %2 = call i64 @test.foo() %not_err1 = icmp eq i64 %2, 0 br i1 %not_err1, label %after_check2, label %end_block3 @@ -65,7 +65,7 @@ end_block4: ; preds = %end_block3 br label %end_block5 end_block5: ; preds = %end_block4 - %3 = call i64 @test_baz(ptr %retparam) + %3 = call i64 @test.baz(ptr %retparam) %not_err6 = icmp eq i64 %3, 0 br i1 %not_err6, label %after_check7, label %end_block8 @@ -74,7 +74,7 @@ after_check7: ; preds = %end_block5 br label %end_block8 end_block8: ; preds = %after_check7, %end_block5 - %5 = call i64 @test_baz(ptr %retparam9) + %5 = call i64 @test.baz(ptr %retparam9) %not_err10 = icmp eq i64 %5, 0 br i1 %not_err10, label %after_check11, label %end_block12 diff --git a/test/test_suite/expressions/chained_conditional.c3t b/test/test_suite/expressions/chained_conditional.c3t index ee0df31dd..021d36198 100644 --- a/test/test_suite/expressions/chained_conditional.c3t +++ b/test/test_suite/expressions/chained_conditional.c3t @@ -27,11 +27,11 @@ entry: %x = alloca i32, align 4 %y = alloca i32, align 4 %z = alloca i32, align 4 - %0 = call i32 @chained_foo() + %0 = call i32 @chained.foo() store i32 %0, ptr %x, align 4 - %1 = call i32 @chained_foo() + %1 = call i32 @chained.foo() store i32 %1, ptr %y, align 4 - %2 = call i32 @chained_foo() + %2 = call i32 @chained.foo() store i32 %2, ptr %z, align 4 %3 = load i32, ptr %x, align 4 %gt = icmp sgt i32 %3, 0 @@ -56,7 +56,7 @@ and.phi4: br i1 %val5, label %if.then, label %if.else if.then: - %6 = call i32 @chained_foo() + %6 = call i32 @chained.foo() br label %if.exit if.else: diff --git a/test/test_suite/expressions/chained_ternary.c3t b/test/test_suite/expressions/chained_ternary.c3t index 14151858d..af8d71ef5 100644 --- a/test/test_suite/expressions/chained_ternary.c3t +++ b/test/test_suite/expressions/chained_ternary.c3t @@ -166,7 +166,7 @@ after_check40: ; preds = %cond.lhs36 br label %cond.phi42 cond.rhs41: ; preds = %after_assign34 - store i64 ptrtoint (ptr @"test_Test$FOO" to i64), ptr %y.f, align 8 + store i64 ptrtoint (ptr @"test.Test$FOO" to i64), ptr %y.f, align 8 br label %after_assign43 cond.phi42: ; preds = %after_check40 @@ -180,7 +180,7 @@ after_assign43: ; preds = %cond.phi42, %cond.r br i1 %not44, label %cond.lhs45, label %cond.rhs46 cond.lhs45: ; preds = %after_assign43 - store i64 ptrtoint (ptr @"test_Test$FOO" to i64), ptr %y.f, align 8 + store i64 ptrtoint (ptr @"test.Test$FOO" to i64), ptr %y.f, align 8 br label %after_assign52 cond.rhs46: ; preds = %after_assign43 @@ -208,11 +208,11 @@ after_assign52: ; preds = %cond.phi51, %assign br i1 %not53, label %cond.lhs54, label %cond.rhs55 cond.lhs54: ; preds = %after_assign52 - store i64 ptrtoint (ptr @"test_Test$FOO" to i64), ptr %y.f, align 8 + store i64 ptrtoint (ptr @"test.Test$FOO" to i64), ptr %y.f, align 8 br label %after_assign57 cond.rhs55: ; preds = %after_assign52 - store i64 ptrtoint (ptr @"test_Test$BAR" to i64), ptr %y.f, align 8 + store i64 ptrtoint (ptr @"test.Test$BAR" to i64), ptr %y.f, align 8 br label %after_assign57 after_assign57: ; preds = %cond.rhs55, %cond.lhs54 diff --git a/test/test_suite/expressions/elvis.c3t b/test/test_suite/expressions/elvis.c3t index 05682ed87..86a464b46 100644 --- a/test/test_suite/expressions/elvis.c3t +++ b/test/test_suite/expressions/elvis.c3t @@ -17,7 +17,7 @@ fn bool elvis3(bool x, bool y) // #expect: elvis.ll -define ptr @elvis_elvis(ptr %0, ptr %1) #0 { +define ptr @elvis.elvis(ptr %0, ptr %1) #0 { entry: %ptrbool = icmp ne ptr %0, null br i1 %ptrbool, label %cond.phi, label %cond.rhs @@ -30,7 +30,7 @@ cond.phi: ; preds = %cond.rhs, %entry ret ptr %val } -define ptr @elvis_elvis2(ptr %0, ptr %1) #0 { +define ptr @elvis.elvis2(ptr %0, ptr %1) #0 { entry: %ptrbool = icmp ne ptr %0, null br i1 %ptrbool, label %cond.phi3, label %cond.rhs @@ -51,7 +51,7 @@ cond.phi3: ; preds = %cond.phi, %entry ret ptr %val4 } -define zeroext i8 @elvis_elvis3(i8 zeroext %0, i8 zeroext %1) #0 { +define zeroext i8 @elvis.elvis3(i8 zeroext %0, i8 zeroext %1) #0 { entry: %2 = trunc i8 %0 to i1 br i1 %2, label %cond.phi, label %cond.rhs diff --git a/test/test_suite/expressions/fmuladd_err.c3t b/test/test_suite/expressions/fmuladd_err.c3t index 1c0cadd09..c45af6c45 100644 --- a/test/test_suite/expressions/fmuladd_err.c3t +++ b/test/test_suite/expressions/fmuladd_err.c3t @@ -18,7 +18,7 @@ fn float easeElasticIn(float t, float b, float c, float d) @inline // Ease: Elas /* #expect: test.ll -define float @test_easeElasticIn(float %0, float %1, float %2, float %3) #0 { +define float @test.easeElasticIn(float %0, float %1, float %2, float %3) #0 { entry: %t = alloca float, align 4 %p = alloca float, align 4 diff --git a/test/test_suite/expressions/folding_ptr.c3t b/test/test_suite/expressions/folding_ptr.c3t index 930d5e112..17320f785 100644 --- a/test/test_suite/expressions/folding_ptr.c3t +++ b/test/test_suite/expressions/folding_ptr.c3t @@ -16,7 +16,7 @@ fn int f() /* #expect: test.ll -define i32 @test_f() #0 { +define i32 @test.f() #0 { entry: %0 = load ptr, ptr @cfun, align 8 %ptroffset = getelementptr %Test, ptr %0, i64 0 diff --git a/test/test_suite/expressions/optional_ternary.c3t b/test/test_suite/expressions/optional_ternary.c3t index 231a3edb0..946a53770 100644 --- a/test/test_suite/expressions/optional_ternary.c3t +++ b/test/test_suite/expressions/optional_ternary.c3t @@ -64,9 +64,9 @@ target triple = "x86_64-apple-darwin" %"char[]" = type { i8*, i64 } %.introspect = type { i8, i64, i64, i64, [0 x i64] } -@"test_Foo$X" = linkonce constant %.fault { i64 ptrtoint (%.introspect* @"ct$test_Foo" to i64), %"char[]" { i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.fault, i64 0, i64 0), i64 1 } }, align 8 +@"test.Foo$X" = linkonce constant %.fault { i64 ptrtoint (%.introspect* @"ct$test.Foo" to i64), %"char[]" { i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.fault, i64 0, i64 0), i64 1 } }, align 8 @.fault = internal constant [2 x i8] c"X\00", align 1 -@"ct$test_Foo" = linkonce constant %.introspect { i8 9, i64 8, i64 0, i64 1, [0 x i64] zeroinitializer }, align 8 +@"ct$test.Foo" = linkonce constant %.introspect { i8 9, i64 8, i64 0, i64 1, [0 x i64] zeroinitializer }, align 8 @.zstr = internal constant [28 x i8] c"Runtime error force unwrap!\00", align 1 @.zstr.1 = internal constant [20 x i8] c"optional_ternary.c3\00", align 1 @.zstr.2 = internal constant [5 x i8] c"main\00", align 1 @@ -78,14 +78,14 @@ target triple = "x86_64-apple-darwin" @.zstr.8 = internal constant [5 x i8] c"main\00", align 1 ; Function Attrs: nounwind -define i64 @test_test(i32* %0, i32 %1) #0 { +define i64 @test.test(i32* %0, i32 %1) #0 { entry: %reterr = alloca i64, align 8 %intbool = icmp ne i32 %1, 0 br i1 %intbool, label %cond.phi, label %cond.rhs cond.rhs: ; preds = %entry - store i64 ptrtoint (%.fault* @"test_Foo$X" to i64), i64* %reterr, align 8 + store i64 ptrtoint (%.fault* @"test.Foo$X" to i64), i64* %reterr, align 8 br label %err_retblock cond.phi: ; preds = %entry @@ -98,18 +98,18 @@ err_retblock: ; preds = %cond.rhs } ; Function Attrs: nounwind -define i64 @test_test2(i32* %0, i32 %1) #0 { +define i64 @test.test2(i32* %0, i32 %1) #0 { entry: %reterr = alloca i64, align 8 %intbool = icmp ne i32 %1, 0 br i1 %intbool, label %cond.lhs, label %cond.rhs cond.lhs: ; preds = %entry - store i64 ptrtoint (%.fault* @"test_Foo$X" to i64), i64* %reterr, align 8 + store i64 ptrtoint (%.fault* @"test.Foo$X" to i64), i64* %reterr, align 8 br label %err_retblock cond.rhs: ; preds = %entry - store i64 ptrtoint (%.fault* @"test_Foo$X" to i64), i64* %reterr, align 8 + store i64 ptrtoint (%.fault* @"test.Foo$X" to i64), i64* %reterr, align 8 br label %err_retblock cond.phi: ; No predecessors! @@ -122,7 +122,7 @@ err_retblock: ; preds = %cond.rhs, %cond.lhs } ; Function Attrs: nounwind -define i64 @test_test3(i32* %0, i32 %1) #0 { +define i64 @test.test3(i32* %0, i32 %1) #0 { entry: %reterr = alloca i64, align 8 %intbool = icmp ne i32 %1, 0 @@ -132,7 +132,7 @@ cond.lhs: ; preds = %entry br label %cond.phi cond.rhs: ; preds = %entry - store i64 ptrtoint (%.fault* @"test_Foo$X" to i64), i64* %reterr, align 8 + store i64 ptrtoint (%.fault* @"test.Foo$X" to i64), i64* %reterr, align 8 br label %err_retblock cond.phi: ; preds = %cond.lhs @@ -145,7 +145,7 @@ err_retblock: ; preds = %cond.rhs } ; Function Attrs: nounwind -define i64 @test_test4(i32* %0, i32 %1) #0 { +define i64 @test.test4(i32* %0, i32 %1) #0 { entry: %y = alloca i32, align 4 %y.f = alloca i64, align 8 @@ -174,7 +174,7 @@ noerr_block: ; preds = %after_check br i1 %intbool, label %cond.phi, label %cond.rhs cond.rhs: ; preds = %noerr_block - store i64 ptrtoint (%.fault* @"test_Foo$X" to i64), i64* %reterr, align 8 + store i64 ptrtoint (%.fault* @"test.Foo$X" to i64), i64* %reterr, align 8 br label %err_retblock cond.phi: ; preds = %noerr_block @@ -187,7 +187,7 @@ err_retblock: ; preds = %cond.rhs } ; Function Attrs: nounwind -define i64 @test_test5(i32* %0, i32 %1) #0 { +define i64 @test.test5(i32* %0, i32 %1) #0 { entry: %y = alloca i32, align 4 %y.f = alloca i64, align 8 @@ -216,11 +216,11 @@ noerr_block: ; preds = %after_check br i1 %intbool, label %cond.lhs, label %cond.rhs cond.lhs: ; preds = %noerr_block - store i64 ptrtoint (%.fault* @"test_Foo$X" to i64), i64* %reterr, align 8 + store i64 ptrtoint (%.fault* @"test.Foo$X" to i64), i64* %reterr, align 8 br label %err_retblock cond.rhs: ; preds = %noerr_block - store i64 ptrtoint (%.fault* @"test_Foo$X" to i64), i64* %reterr, align 8 + store i64 ptrtoint (%.fault* @"test.Foo$X" to i64), i64* %reterr, align 8 br label %err_retblock cond.phi: ; No predecessors! @@ -233,7 +233,7 @@ err_retblock: ; preds = %cond.rhs, %cond.lhs } ; Function Attrs: nounwind -define i64 @test_test6(i32* %0, i32 %1) #0 { +define i64 @test.test6(i32* %0, i32 %1) #0 { entry: %y = alloca i32, align 4 %y.f = alloca i64, align 8 @@ -265,7 +265,7 @@ cond.lhs: ; preds = %noerr_block br label %cond.phi cond.rhs: ; preds = %noerr_block - store i64 ptrtoint (%.fault* @"test_Foo$X" to i64), i64* %reterr, align 8 + store i64 ptrtoint (%.fault* @"test.Foo$X" to i64), i64* %reterr, align 8 br label %err_retblock cond.phi: ; preds = %cond.lhs @@ -278,7 +278,7 @@ err_retblock: ; preds = %cond.rhs } ; Function Attrs: nounwind -define i64 @test_test7(i32* %0, i32 %1) #0 { +define i64 @test.test7(i32* %0, i32 %1) #0 { entry: %y = alloca i32, align 4 %y.f = alloca i64, align 8 @@ -307,7 +307,7 @@ noerr_block: ; preds = %after_check br i1 %intbool, label %cond.lhs, label %cond.rhs cond.lhs: ; preds = %noerr_block - store i64 ptrtoint (%.fault* @"test_Foo$X" to i64), i64* %reterr, align 8 + store i64 ptrtoint (%.fault* @"test.Foo$X" to i64), i64* %reterr, align 8 br label %err_retblock cond.rhs: ; preds = %noerr_block @@ -323,7 +323,7 @@ err_retblock: ; preds = %cond.lhs } ; Function Attrs: nounwind -define void @test_main() #0 { +define void @test.main() #0 { entry: %error_var = alloca i64, align 8 %retparam = alloca i32, align 4 @@ -334,7 +334,7 @@ entry: %i = alloca i32, align 4 %i.f = alloca i64, align 8 %retparam15 = alloca i32, align 4 - %0 = call i64 @test_test(i32* %retparam, i32 1) + %0 = call i64 @test.test(i32* %retparam, i32 1) %not_err = icmp eq i64 %0, 0 br i1 %not_err, label %after_check, label %assign_optional @@ -347,11 +347,11 @@ after_check: ; preds = %entry br label %noerr_block panic_block: ; preds = %assign_optional - call void @std_core_builtin_panic(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.zstr, i64 0, i64 0), i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.zstr.1, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.zstr.2, i64 0, i64 0), i32 51) + call void @std_core_builtin.panic(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.zstr, i64 0, i64 0), i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.zstr.1, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.zstr.2, i64 0, i64 0), i32 51) unreachable noerr_block: ; preds = %after_check - %2 = call i64 @test_test7(i32* %retparam2, i32 0) + %2 = call i64 @test.test7(i32* %retparam2, i32 0) %not_err3 = icmp eq i64 %2, 0 br i1 %not_err3, label %after_check5, label %assign_optional4 @@ -364,11 +364,11 @@ after_check5: ; preds = %noerr_block br label %noerr_block7 panic_block6: ; preds = %assign_optional4 - call void @std_core_builtin_panic(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.zstr.3, i64 0, i64 0), i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.zstr.4, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.zstr.5, i64 0, i64 0), i32 52) + call void @std_core_builtin.panic(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.zstr.3, i64 0, i64 0), i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.zstr.4, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.zstr.5, i64 0, i64 0), i32 52) unreachable noerr_block7: ; preds = %after_check5 - %4 = call i64 @test_test6(i32* %retparam9, i32 1) + %4 = call i64 @test.test6(i32* %retparam9, i32 1) %not_err10 = icmp eq i64 %4, 0 br i1 %not_err10, label %after_check12, label %assign_optional11 @@ -381,11 +381,11 @@ after_check12: ; preds = %noerr_block7 br label %noerr_block14 panic_block13: ; preds = %assign_optional11 - call void @std_core_builtin_panic(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.zstr.6, i64 0, i64 0), i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.zstr.7, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.zstr.8, i64 0, i64 0), i32 53) + call void @std_core_builtin.panic(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.zstr.6, i64 0, i64 0), i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.zstr.7, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.zstr.8, i64 0, i64 0), i32 53) unreachable noerr_block14: ; preds = %after_check12 - %6 = call i64 @test_test2(i32* %retparam15, i32 3) + %6 = call i64 @test.test2(i32* %retparam15, i32 3) %not_err16 = icmp eq i64 %6, 0 br i1 %not_err16, label %after_check18, label %assign_optional17 @@ -406,10 +406,10 @@ after_assign: ; preds = %after_check18, %ass ; Function Attrs: nounwind define i32 @main(i32 %0, i8** %1) #0 { entry: - call void @test_main() + call void @test.main() ret i32 0 } -declare void @std_core_builtin_panic(i8*, i8*, i8*, i32) +declare void @std_core_builtin.panic(i8*, i8*, i8*, i32) attributes #0 = { nounwind } \ No newline at end of file diff --git a/test/test_suite/expressions/parsed_numbers.c3t b/test/test_suite/expressions/parsed_numbers.c3t index cb4e46d16..ce2809a64 100644 --- a/test/test_suite/expressions/parsed_numbers.c3t +++ b/test/test_suite/expressions/parsed_numbers.c3t @@ -7,7 +7,7 @@ double d = 12.3e+12; // #expect: numbers.ll -@numbers_a = local_unnamed_addr global double 2.125000e+00, align 8 -@numbers_b = local_unnamed_addr global double -1.230000e-11, align 8 -@numbers_c = local_unnamed_addr global double 5.312500e-01, align 8 -@numbers_d = local_unnamed_addr global double 1.230000e+13, align 8 \ No newline at end of file +@numbers.a = local_unnamed_addr global double 2.125000e+00, align 8 +@numbers.b = local_unnamed_addr global double -1.230000e-11, align 8 +@numbers.c = local_unnamed_addr global double 5.312500e-01, align 8 +@numbers.d = local_unnamed_addr global double 1.230000e+13, align 8 \ No newline at end of file diff --git a/test/test_suite/expressions/pointer_access.c3t b/test/test_suite/expressions/pointer_access.c3t index 66aba105f..a5c04bb16 100644 --- a/test/test_suite/expressions/pointer_access.c3t +++ b/test/test_suite/expressions/pointer_access.c3t @@ -42,13 +42,13 @@ fn void testSimple() %.anon = type { i32, i32 } %.anon.0 = type { double } -@"ct$pointer_access_c" = linkonce constant %.introspect { i8 10, i64 40, i64 0, i64 5, [0 x i64] zeroinitializer }, align 8 -@"ct$pointer_access_$anon" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 -@"ct$pointer_access_$anon.4" = linkonce constant %.introspect { i8 11, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 -@"ct$pointer_access_ExtraSimple" = linkonce constant %.introspect { i8 10, i64 72, i64 0, i64 6, [0 x i64] zeroinitializer }, align 8 +@"ct$pointer_access.c" = linkonce constant %.introspect { i8 10, i64 40, i64 0, i64 5, [0 x i64] zeroinitializer }, align 8 +@"ct$pointer_access.$anon" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 +@"ct$pointer_access.$anon.4" = linkonce constant %.introspect { i8 11, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 +@"ct$pointer_access.ExtraSimple" = linkonce constant %.introspect { i8 10, i64 72, i64 0, i64 6, [0 x i64] zeroinitializer }, align 8 @.str = private unnamed_addr constant [71 x i8] c"a = %d, c.e = %f, c.f = %f, c.j = %f, g = %d, o0 = %f, r = %d, s = %d\0A\00", align 1 -define void @pointer_access_testSimple() #0 { +define void @pointer_access.testSimple() #0 { entry: %a = alloca %ExtraSimple, align 8 %0 = getelementptr inbounds %ExtraSimple, ptr %a, i32 0, i32 0 diff --git a/test/test_suite/expressions/simple_float_sub_neg.c3t b/test/test_suite/expressions/simple_float_sub_neg.c3t index 73d01cbd0..79cb304ab 100644 --- a/test/test_suite/expressions/simple_float_sub_neg.c3t +++ b/test/test_suite/expressions/simple_float_sub_neg.c3t @@ -7,7 +7,7 @@ fn double test(double a, double b, double c, double d) // #expect: simple_float_sub_neg.ll -define double @simple_float_sub_neg_test(double %0, double %1, double %2, double %3) #0 { +define double @simple_float_sub_neg.test(double %0, double %1, double %2, double %3) #0 { entry: %fsub = fsub double %0, %1 %fneg = fneg double %fsub diff --git a/test/test_suite/expressions/ternary_bool.c3t b/test/test_suite/expressions/ternary_bool.c3t index fe89ad342..bc8ee4499 100644 --- a/test/test_suite/expressions/ternary_bool.c3t +++ b/test/test_suite/expressions/ternary_bool.c3t @@ -15,7 +15,7 @@ fn void main() /* #expect: ternary_bool.ll -define void @ternary_bool_main() #0 { +define void @ternary_bool.main() #0 { entry: %b = alloca i8, align 1 %c = alloca ptr, align 8 diff --git a/test/test_suite/floats/convert_float.c3t b/test/test_suite/floats/convert_float.c3t index 533849d35..cb06a173e 100644 --- a/test/test_suite/floats/convert_float.c3t +++ b/test/test_suite/floats/convert_float.c3t @@ -9,7 +9,7 @@ fn void test() } /* #expect: foo.ll -define void @foo_test() #0 { +define void @foo.test() #0 { entry: %x = alloca float, align 4 %y = alloca double, align 8 diff --git a/test/test_suite/floats/mod.c3t b/test/test_suite/floats/mod.c3t index 136d8a2f5..54762f05a 100644 --- a/test/test_suite/floats/mod.c3t +++ b/test/test_suite/floats/mod.c3t @@ -7,7 +7,7 @@ fn double x(double a, double b) /* #expect: mod.ll -define double @mod_x(double %0, double %1) #0 { +define double @mod.x(double %0, double %1) #0 { entry: %fmod = frem double %0, %1 ret double %fmod diff --git a/test/test_suite/from_docs/examples_defer.c3t b/test/test_suite/from_docs/examples_defer.c3t index 7084adcfc..95bb93e7c 100644 --- a/test/test_suite/from_docs/examples_defer.c3t +++ b/test/test_suite/from_docs/examples_defer.c3t @@ -23,21 +23,21 @@ fn void main() /* #expect: defer1.ll -define void @defer1_test(i32 %0) #0 { +define void @defer1.test(i32 %0) #0 { entry: %eq = icmp eq i32 %0, 1 br i1 %eq, label %if.then, label %if.exit if.then: ; preds = %entry store ptr @.str, ptr %x, align 8 - %1 = call ptr @std_io_stdout() + %1 = call ptr @std_io.stdout() store ptr %1, ptr %result, align 8 %2 = load ptr, ptr %x, align 8 - %3 = call i64 @std_io_File_print(ptr %retparam, ptr %result, ptr %2, i64 1) + %3 = call i64 @std_io.File_print(ptr %retparam, ptr %result, ptr %2, i64 1) store ptr @.str.1, ptr %x1, align 8 - %4 = call ptr @std_io_stdout() + %4 = call ptr @std_io.stdout() store ptr %4, ptr %result3, align 8 - %5 = call i64 @std_io_File_printn(ptr %retparam2, ptr %result3, ptr null, i64 0) + %5 = call i64 @std_io.File_printn(ptr %retparam2, ptr %result3, ptr null, i64 0) ret void if.exit: ; preds = %entry @@ -46,49 +46,49 @@ if.exit: ; preds = %entry if.then5: ; preds = %if.exit store ptr @.str.2, ptr %x6, align 8 - %6 = call ptr @std_io_stdout() + %6 = call ptr @std_io.stdout() store ptr %6, ptr %result8, align 8 %7 = load ptr, ptr %x6, align 8 - %8 = call i64 @std_io_File_print(ptr %retparam7, ptr %result8, ptr %7, i64 1) + %8 = call i64 @std_io.File_print(ptr %retparam7, ptr %result8, ptr %7, i64 1) store ptr @.str.3, ptr %x9, align 8 - %9 = call ptr @std_io_stdout() + %9 = call ptr @std_io.stdout() store ptr %9, ptr %result11, align 8 %10 = load ptr, ptr %x9, align 8 - %11 = call i64 @std_io_File_print(ptr %retparam10, ptr %result11, ptr %10, i64 1) + %11 = call i64 @std_io.File_print(ptr %retparam10, ptr %result11, ptr %10, i64 1) store ptr @.str.4, ptr %x12, align 8 - %12 = call ptr @std_io_stdout() + %12 = call ptr @std_io.stdout() store ptr %12, ptr %result14, align 8 - %13 = call i64 @std_io_File_printn(ptr %retparam13, ptr %result14, ptr null, i64 0) + %13 = call i64 @std_io.File_printn(ptr %retparam13, ptr %result14, ptr null, i64 0) ret void if.exit15: ; preds = %if.exit store ptr @.str.5, ptr %x16, align 8 - %14 = call ptr @std_io_stdout() + %14 = call ptr @std_io.stdout() store ptr %14, ptr %result18, align 8 %15 = load ptr, ptr %x16, align 8 - %16 = call i64 @std_io_File_print(ptr %retparam17, ptr %result18, ptr %15, i64 1) + %16 = call i64 @std_io.File_print(ptr %retparam17, ptr %result18, ptr %15, i64 1) store ptr @.str.6, ptr %x19, align 8 - %17 = call ptr @std_io_stdout() + %17 = call ptr @std_io.stdout() store ptr %17, ptr %result21, align 8 %18 = load ptr, ptr %x19, align 8 - %19 = call i64 @std_io_File_print(ptr %retparam20, ptr %result21, ptr %18, i64 1) + %19 = call i64 @std_io.File_print(ptr %retparam20, ptr %result21, ptr %18, i64 1) store ptr @.str.7, ptr %x22, align 8 - %20 = call ptr @std_io_stdout() + %20 = call ptr @std_io.stdout() store ptr %20, ptr %result24, align 8 %21 = load ptr, ptr %x22, align 8 - %22 = call i64 @std_io_File_print(ptr %retparam23, ptr %result24, ptr %21, i64 1) + %22 = call i64 @std_io.File_print(ptr %retparam23, ptr %result24, ptr %21, i64 1) store ptr @.str.8, ptr %x25, align 8 - %23 = call ptr @std_io_stdout() + %23 = call ptr @std_io.stdout() store ptr %23, ptr %result27, align 8 - %24 = call i64 @std_io_File_printn(ptr %retparam26, ptr %result27, ptr null, i64 0) + %24 = call i64 @std_io.File_printn(ptr %retparam26, ptr %result27, ptr null, i64 0) ret void } -define void @defer1_main() #0 { +define void @defer1.main() #0 { entry: - call void @defer1_test(i32 1) - call void @defer1_test(i32 0) - call void @defer1_test(i32 10) + call void @defer1.test(i32 1) + call void @defer1.test(i32 0) + call void @defer1.test(i32 10) ret void } diff --git a/test/test_suite/from_docs/examples_forswitch.c3t b/test/test_suite/from_docs/examples_forswitch.c3t index 54c5236e7..722b898b4 100644 --- a/test/test_suite/from_docs/examples_forswitch.c3t +++ b/test/test_suite/from_docs/examples_forswitch.c3t @@ -89,7 +89,7 @@ fn void demo_enum(Height h) } /* #expect: examples.ll -define void @examples_example_for() #0 { +define void @examples.example_for() #0 { entry: %i = alloca i32, align 4 store i32 0, ptr %i, align 4 @@ -109,7 +109,7 @@ loop.body: ; preds = %loop.cond br label %loop.cond loop.exit: ; preds = %loop.cond - %4 = load ptr, ptr @std_core_builtin_panic, align 8 + %4 = load ptr, ptr @std_core_builtin.panic, align 8 call void %4(ptr @.panic_msg, i64 19, ptr @.file, i64 21, ptr @.func, i64 11, i32 14) unreachable @@ -118,7 +118,7 @@ unreachable_block: ; No predecessors! } ; Function Attrs: nounwind -define void @examples_demo_enum(i32 %0) #0 { +define void @examples.demo_enum(i32 %0) #0 { entry: %switch = alloca i32, align 4 %x = alloca ptr, align 8 @@ -164,18 +164,18 @@ switch.entry: ; preds = %entry switch.case: ; preds = %switch.entry, %switch.entry store ptr @.str.1, ptr %x, align 8 - %2 = call ptr @std_io_stdout() + %2 = call ptr @std_io.stdout() store ptr %2, ptr %result, align 8 %3 = load ptr, ptr %x, align 8 - %4 = call i64 @std_io_File_printn(ptr %retparam, ptr %result, ptr %3, i64 8) + %4 = call i64 @std_io.File_printn(ptr %retparam, ptr %result, ptr %3, i64 8) br label %switch.exit switch.case1: ; preds = %switch.entry store ptr @.str.2, ptr %x2, align 8 - %5 = call ptr @std_io_stdout() + %5 = call ptr @std_io.stdout() store ptr %5, ptr %result4, align 8 %6 = load ptr, ptr %x2, align 8 - %7 = call i64 @std_io_File_printn(ptr %retparam3, ptr %result4, ptr %6, i64 4) + %7 = call i64 @std_io.File_printn(ptr %retparam3, ptr %result4, ptr %6, i64 4) br label %switch.exit switch.exit: ; preds = %switch.case1, %switch.case, %switch.entry @@ -192,18 +192,18 @@ switch.entry6: ; preds = %switch.exit switch.case7: ; preds = %switch.entry6, %switch.entry6 store ptr @.str.3, ptr %x8, align 8 - %9 = call ptr @std_io_stdout() + %9 = call ptr @std_io.stdout() store ptr %9, ptr %result10, align 8 %10 = load ptr, ptr %x8, align 8 - %11 = call i64 @std_io_File_printn(ptr %retparam9, ptr %result10, ptr %10, i64 8) + %11 = call i64 @std_io.File_printn(ptr %retparam9, ptr %result10, ptr %10, i64 8) br label %switch.exit15 switch.case11: ; preds = %switch.entry6 store ptr @.str.4, ptr %x12, align 8 - %12 = call ptr @std_io_stdout() + %12 = call ptr @std_io.stdout() store ptr %12, ptr %result14, align 8 %13 = load ptr, ptr %x12, align 8 - %14 = call i64 @std_io_File_printn(ptr %retparam13, ptr %result14, ptr %13, i64 4) + %14 = call i64 @std_io.File_printn(ptr %retparam13, ptr %result14, ptr %13, i64 4) br label %switch.exit15 switch.exit15: ; preds = %switch.case11, %switch.case7, %switch.entry6 @@ -223,10 +223,10 @@ switch.case18: ; preds = %switch.entry17 switch.case19: ; preds = %switch.entry17 store ptr @.str.5, ptr %x20, align 8 - %16 = call ptr @std_io_stdout() + %16 = call ptr @std_io.stdout() store ptr %16, ptr %result22, align 8 %17 = load ptr, ptr %x20, align 8 - %18 = call i64 @std_io_File_printn(ptr %retparam21, ptr %result22, ptr %17, i64 6) + %18 = call i64 @std_io.File_printn(ptr %retparam21, ptr %result22, ptr %17, i64 6) br label %switch.exit24 switch.case23: ; preds = %switch.entry17 @@ -265,27 +265,27 @@ switch.entry30: ; preds = %switch.exit28 switch.case31: ; preds = %switch.entry30 store i32 1, ptr %a, align 4 store ptr @.str.6, ptr %x32, align 8 - %21 = call ptr @std_io_stdout() + %21 = call ptr @std_io.stdout() store ptr %21, ptr %result34, align 8 %22 = load ptr, ptr %x32, align 8 - %23 = call i64 @std_io_File_printn(ptr %retparam33, ptr %result34, ptr %22, i64 1) + %23 = call i64 @std_io.File_printn(ptr %retparam33, ptr %result34, ptr %22, i64 1) br label %switch.case35 switch.case35: ; preds = %switch.entry30, %switch.case31 store i32 2, ptr %a36, align 4 store ptr @.str.7, ptr %x37, align 8 - %24 = call ptr @std_io_stdout() + %24 = call ptr @std_io.stdout() store ptr %24, ptr %result39, align 8 %25 = load ptr, ptr %x37, align 8 - %26 = call i64 @std_io_File_printn(ptr %retparam38, ptr %result39, ptr %25, i64 1) + %26 = call i64 @std_io.File_printn(ptr %retparam38, ptr %result39, ptr %25, i64 1) br label %switch.case40 switch.case40: ; preds = %switch.entry30, %switch.case35 store ptr @.str.8, ptr %x41, align 8 - %27 = call ptr @std_io_stdout() + %27 = call ptr @std_io.stdout() store ptr %27, ptr %result43, align 8 %28 = load ptr, ptr %x41, align 8 - %29 = call i64 @std_io_File_printn(ptr %retparam42, ptr %result43, ptr %28, i64 1) + %29 = call i64 @std_io.File_printn(ptr %retparam42, ptr %result43, ptr %28, i64 1) br label %switch.exit44 switch.exit44: ; preds = %switch.case40, %switch.entry30 diff --git a/test/test_suite/from_docs/examples_functionpointer.c3t b/test/test_suite/from_docs/examples_functionpointer.c3t index 4f757ce61..0aee28f13 100644 --- a/test/test_suite/from_docs/examples_functionpointer.c3t +++ b/test/test_suite/from_docs/examples_functionpointer.c3t @@ -19,15 +19,15 @@ fn void main() /* #expect: demo.ll -define i32 @demo_my_callback(ptr %0, i32 %1) #0 { +define i32 @demo.my_callback(ptr %0, i32 %1) #0 { entry: ret i32 0 } -define void @demo_main() #0 { +define void @demo.main() #0 { entry: %result = alloca i32, align 4 - %0 = load ptr, ptr @demo_cb, align 8 + %0 = load ptr, ptr @demo.cb, align 8 %1 = call i32 %0(ptr @.str, i32 123) store i32 %1, ptr %result, align 4 ret void diff --git a/test/test_suite/from_docs/examples_if_catch.c3t b/test/test_suite/from_docs/examples_if_catch.c3t index aed7fa452..0b39975a2 100644 --- a/test/test_suite/from_docs/examples_if_catch.c3t +++ b/test/test_suite/from_docs/examples_if_catch.c3t @@ -46,13 +46,13 @@ fn void main() /* #expect: demo.ll -define i64 @demo_divide(ptr %0, i32 %1, i32 %2) #0 { +define i64 @demo.divide(ptr %0, i32 %1, i32 %2) #0 { entry: %reterr = alloca i64, align 8 %eq = icmp eq i32 %2, 0 br i1 %eq, label %if.then, label %if.exit if.then: ; preds = %entry - ret i64 ptrtoint (ptr @"demo_MathError$DIVISION_BY_ZERO" to i64) + ret i64 ptrtoint (ptr @"demo.MathError$DIVISION_BY_ZERO" to i64) if.exit: ; preds = %entry %sifp = sitofp i32 %1 to double %sifp1 = sitofp i32 %2 to double @@ -61,14 +61,14 @@ if.exit: ; preds = %entry ret i64 0 } -define i64 @demo_testMayError() #0 { +define i64 @demo.testMayError() #0 { entry: %error_var = alloca i64, align 8 %retparam = alloca double, align 8 %reterr = alloca i64, align 8 - %0 = call i32 @demo_foo() - %1 = call i32 @demo_bar() - %2 = call i64 @demo_divide(ptr %retparam, i32 %0, i32 %1) + %0 = call i32 @demo.foo() + %1 = call i32 @demo.bar() + %2 = call i64 @demo.divide(ptr %retparam, i32 %0, i32 %1) %not_err = icmp eq i64 %2, 0 %3 = call i1 @llvm.expect.i1(i1 %not_err, i1 true) br i1 %3, label %after_check, label %assign_optional @@ -84,16 +84,16 @@ noerr_block: ; preds = %after_check ret i64 0 } -define void @demo_main() #0 { +define void @demo.main() #0 { entry: %ratio = alloca double, align 8 %ratio.f = alloca i64, align 8 %retparam = alloca double, align 8 %err = alloca i64, align 8 %switch = alloca i64, align 8 - %0 = call i32 @demo_foo() - %1 = call i32 @demo_bar() - %2 = call i64 @demo_divide(ptr %retparam, i32 %0, i32 %1) + %0 = call i32 @demo.foo() + %1 = call i32 @demo.bar() + %2 = call i64 @demo.divide(ptr %retparam, i32 %0, i32 %1) %not_err = icmp eq i64 %2, 0 %3 = call i1 @llvm.expect.i1(i1 %not_err, i1 true) br i1 %3, label %after_check, label %assign_optional @@ -127,7 +127,7 @@ if.then: ; preds = %end_block br label %switch.entry switch.entry: ; preds = %if.then %7 = load i64, ptr %switch, align 8 - %eq = icmp eq i64 ptrtoint (ptr @"demo_MathError$DIVISION_BY_ZERO" to i64), %7 + %eq = icmp eq i64 ptrtoint (ptr @"demo.MathError$DIVISION_BY_ZERO" to i64), %7 br i1 %eq, label %switch.case, label %next_if switch.case: ; preds = %switch.entry %8 = call i32 (ptr, ...) @printf(ptr @.str) diff --git a/test/test_suite/from_docs/examples_macro_function.c3t b/test/test_suite/from_docs/examples_macro_function.c3t index 20cd4ae5c..860ed506b 100644 --- a/test/test_suite/from_docs/examples_macro_function.c3t +++ b/test/test_suite/from_docs/examples_macro_function.c3t @@ -23,13 +23,13 @@ fn int test() /* #expect: example.ll -define i32 @example_square(i32 %0) #0 { +define i32 @example.square(i32 %0) #0 { entry: %mul = mul i32 %0, %0 ret i32 %mul } -define i32 @example_test() #0 { +define i32 @example.test() #0 { entry: %a = alloca i32, align 4 %b = alloca i32, align 4 @@ -37,7 +37,7 @@ entry: %b2 = alloca i32, align 4 store i32 2, ptr %a, align 4 store i32 3, ptr %b, align 4 - store ptr @example_square, ptr %a1, align 8 + store ptr @example.square, ptr %a1, align 8 store i32 2, ptr %b2, align 4 %0 = load ptr, ptr %a1, align 8 %1 = load i32, ptr %b2, align 4 diff --git a/test/test_suite/functions/assorted_tests.c3t b/test/test_suite/functions/assorted_tests.c3t index b939d8473..8166b70f1 100644 --- a/test/test_suite/functions/assorted_tests.c3t +++ b/test/test_suite/functions/assorted_tests.c3t @@ -51,7 +51,7 @@ fn void denormalize(InternalFPF* ptr) /* #expect: test.ll -define i32 @test_foo1() #0 { +define i32 @test.foo1() #0 { entry: %pp = alloca ptr, align 8 %w_cnt = alloca i32, align 4 @@ -65,7 +65,7 @@ entry: ret i32 %3 } -define void @test_foo2(i32 %0) #0 { +define void @test.foo2(i32 %0) #0 { entry: %intbool = icmp ne i32 %0, 0 %ternary = select i1 %intbool, double 1.000000e+00, double 1.250000e+01 @@ -73,7 +73,7 @@ entry: ret void } -define i32 @test_trys(ptr %0, i32 %1) #0 { +define i32 @test.trys(ptr %0, i32 %1) #0 { entry: %asa = alloca i32, align 4 %val = alloca double, align 8 @@ -96,15 +96,15 @@ if.exit: ; preds = %if.then, %entry ret i32 %add1 } -define void @test_setInternalFPFZero(ptr %0) #1 { +define void @test.setInternalFPFZero(ptr %0) #1 { entry: %1 = getelementptr inbounds %InternalFPF, ptr %0, i32 0, i32 0 store i8 0, ptr %1, align 1 ret void } -define void @test_denormalize(ptr %0) #0 { +define void @test.denormalize(ptr %0) #0 { entry: - call void @test_setInternalFPFZero(ptr %0) + call void @test.setInternalFPFZero(ptr %0) ret void } diff --git a/test/test_suite/functions/defered_default_arguments.c3t b/test/test_suite/functions/defered_default_arguments.c3t index 2510dff2f..86bb5b7fb 100644 --- a/test/test_suite/functions/defered_default_arguments.c3t +++ b/test/test_suite/functions/defered_default_arguments.c3t @@ -37,20 +37,20 @@ fn void main() // #expect: test3.ll entry: - call void @test_test(i32 1, i32 2) - %0 = call i32 @test2_foo() - call void @test_test(i32 3, i32 %0) - call void @test_test(i32 1, i32 32) + call void @test.test(i32 1, i32 2) + %0 = call i32 @test2.foo() + call void @test.test(i32 3, i32 %0) + call void @test.test(i32 1, i32 32) %1 = load i32, ptr @"main$x", align 4 %add = add i32 %1, 1 store i32 %add, ptr @"main$x", align 4 - %2 = call i32 @test2_foo() - call void @test_test(i32 %add, i32 %2) + %2 = call i32 @test2.foo() + call void @test.test(i32 %add, i32 %2) %3 = load i32, ptr @"main$x.1", align 4 %add1 = add i32 %3, 1 store i32 %add1, ptr @"main$x.1", align 4 - %4 = call i32 @test2_foo() - call void @test_test(i32 %add1, i32 %4) + %4 = call i32 @test2.foo() + call void @test.test(i32 %add1, i32 %4) ret void } diff --git a/test/test_suite/functions/func_ptr_conversions_and_names.c3t b/test/test_suite/functions/func_ptr_conversions_and_names.c3t index 9fc68b529..e69b640a3 100644 --- a/test/test_suite/functions/func_ptr_conversions_and_names.c3t +++ b/test/test_suite/functions/func_ptr_conversions_and_names.c3t @@ -55,7 +55,7 @@ fn void main() @"ct$fn$int$int$" = linkonce constant %.introspect { i8 13, i64 8, i64 0, i64 0, [0 x i64] zeroinitializer }, align 8 @"ct$p$fn$int$int$" = linkonce constant %.introspect { i8 19, i64 8, i64 ptrtoint (ptr @"ct$fn$int$int$" to i64), i64 0, [0 x i64] zeroinitializer }, align 8 -define void @test_main() #0 { +define void @test.main() #0 { entry: %a = alloca ptr, align 8 %b = alloca ptr, align 8 @@ -86,8 +86,8 @@ entry: %taddr21 = alloca ptr, align 8 %y = alloca ptr, align 8 %zfoke = alloca i64, align 8 - store ptr @test_test, ptr %a, align 8 - store ptr @test_test2, ptr %b, align 8 + store ptr @test.test, ptr %a, align 8 + store ptr @test.test2, ptr %b, align 8 %0 = load ptr, ptr %a, align 8 %1 = call i32 %0(i32 123) store i32 %1, ptr %taddr, align 4 @@ -95,15 +95,15 @@ entry: %3 = insertvalue %variant %2, i64 ptrtoint (ptr @"ct$int" to i64), 1 %4 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %3, ptr %4, align 16 - %5 = call i64 @std_io_printfn(ptr %retparam, ptr @.str, i64 2, ptr %varargslots, i64 1) - %6 = call i32 @test_test2(i32 3) + %5 = call i64 @std_io.printfn(ptr %retparam, ptr @.str, i64 2, ptr %varargslots, i64 1) + %6 = call i32 @test.test2(i32 3) store i32 %6, ptr %taddr3, align 4 %7 = insertvalue %variant undef, ptr %taddr3, 0 %8 = insertvalue %variant %7, i64 ptrtoint (ptr @"ct$int" to i64), 1 %9 = getelementptr inbounds [1 x %variant], ptr %varargslots2, i64 0, i64 0 store %variant %8, ptr %9, align 16 - %10 = call i64 @std_io_printfn(ptr %retparam1, ptr @.str.1, i64 2, ptr %varargslots2, i64 1) - store ptr @test_test2, ptr %z, align 8 + %10 = call i64 @std_io.printfn(ptr %retparam1, ptr @.str.1, i64 2, ptr %varargslots2, i64 1) + store ptr @test.test2, ptr %z, align 8 %11 = load ptr, ptr %z, align 8 %12 = call i32 %11(i32 444) store i32 %12, ptr %taddr6, align 4 @@ -111,38 +111,38 @@ entry: %14 = insertvalue %variant %13, i64 ptrtoint (ptr @"ct$int" to i64), 1 %15 = getelementptr inbounds [1 x %variant], ptr %varargslots5, i64 0, i64 0 store %variant %14, ptr %15, align 16 - %16 = call i64 @std_io_printfn(ptr %retparam4, ptr @.str.2, i64 2, ptr %varargslots5, i64 1) + %16 = call i64 @std_io.printfn(ptr %retparam4, ptr @.str.2, i64 2, ptr %varargslots5, i64 1) store ptr @.str.4, ptr %taddr9, align 8 %17 = insertvalue %variant undef, ptr %taddr9, 0 %18 = insertvalue %variant %17, i64 ptrtoint (ptr @"ct$p$a12$char" to i64), 1 %19 = getelementptr inbounds [1 x %variant], ptr %varargslots8, i64 0, i64 0 store %variant %18, ptr %19, align 16 - %20 = call i64 @std_io_printfn(ptr %retparam7, ptr @.str.3, i64 2, ptr %varargslots8, i64 1) + %20 = call i64 @std_io.printfn(ptr %retparam7, ptr @.str.3, i64 2, ptr %varargslots8, i64 1) store ptr @.str.6, ptr %taddr12, align 8 %21 = insertvalue %variant undef, ptr %taddr12, 0 %22 = insertvalue %variant %21, i64 ptrtoint (ptr @"ct$p$a12$char" to i64), 1 %23 = getelementptr inbounds [1 x %variant], ptr %varargslots11, i64 0, i64 0 store %variant %22, ptr %23, align 16 - %24 = call i64 @std_io_printfn(ptr %retparam10, ptr @.str.5, i64 2, ptr %varargslots11, i64 1) + %24 = call i64 @std_io.printfn(ptr %retparam10, ptr @.str.5, i64 2, ptr %varargslots11, i64 1) store ptr @.str.8, ptr %taddr15, align 8 %25 = insertvalue %variant undef, ptr %taddr15, 0 %26 = insertvalue %variant %25, i64 ptrtoint (ptr @"ct$p$a12$char" to i64), 1 %27 = getelementptr inbounds [1 x %variant], ptr %varargslots14, i64 0, i64 0 store %variant %26, ptr %27, align 16 - %28 = call i64 @std_io_printfn(ptr %retparam13, ptr @.str.7, i64 2, ptr %varargslots14, i64 1) + %28 = call i64 @std_io.printfn(ptr %retparam13, ptr @.str.7, i64 2, ptr %varargslots14, i64 1) store ptr @.str.10, ptr %taddr18, align 8 %29 = insertvalue %variant undef, ptr %taddr18, 0 %30 = insertvalue %variant %29, i64 ptrtoint (ptr @"ct$p$a6$char" to i64), 1 %31 = getelementptr inbounds [1 x %variant], ptr %varargslots17, i64 0, i64 0 store %variant %30, ptr %31, align 16 - %32 = call i64 @std_io_printfn(ptr %retparam16, ptr @.str.9, i64 2, ptr %varargslots17, i64 1) + %32 = call i64 @std_io.printfn(ptr %retparam16, ptr @.str.9, i64 2, ptr %varargslots17, i64 1) store ptr @.str.12, ptr %taddr21, align 8 %33 = insertvalue %variant undef, ptr %taddr21, 0 %34 = insertvalue %variant %33, i64 ptrtoint (ptr @"ct$p$a13$char" to i64), 1 %35 = getelementptr inbounds [1 x %variant], ptr %varargslots20, i64 0, i64 0 store %variant %34, ptr %35, align 16 - %36 = call i64 @std_io_printfn(ptr %retparam19, ptr @.str.11, i64 2, ptr %varargslots20, i64 1) - store ptr @test_test2, ptr %y, align 8 + %36 = call i64 @std_io.printfn(ptr %retparam19, ptr @.str.11, i64 2, ptr %varargslots20, i64 1) + store ptr @test.test2, ptr %y, align 8 store i64 ptrtoint (ptr @"ct$p$fn$int$int$" to i64), ptr %zfoke, align 8 ret void } diff --git a/test/test_suite/functions/naked_function.c3t b/test/test_suite/functions/naked_function.c3t index 55830a596..40c906f5d 100644 --- a/test/test_suite/functions/naked_function.c3t +++ b/test/test_suite/functions/naked_function.c3t @@ -7,7 +7,7 @@ fn void test(int i) @naked /* #expect: naked_function.ll -define void @naked_function_test(i32 %0) #0 { +define void @naked_function.test(i32 %0) #0 { entry: ret void } diff --git a/test/test_suite/functions/returning_void.c3t b/test/test_suite/functions/returning_void.c3t index 6b6d3bd50..e93e09790 100644 --- a/test/test_suite/functions/returning_void.c3t +++ b/test/test_suite/functions/returning_void.c3t @@ -16,5 +16,5 @@ if.then: ret void if.exit: - call void @returning_void_test1() + call void @returning_void.test1() ret void diff --git a/test/test_suite/functions/simple_test.c3t b/test/test_suite/functions/simple_test.c3t index bb4244a87..2949cc5b1 100644 --- a/test/test_suite/functions/simple_test.c3t +++ b/test/test_suite/functions/simple_test.c3t @@ -13,7 +13,7 @@ fn int foo() /* #expect: simple_test.ll -define i32 @simple_test_foo() #0 { +define i32 @simple_test.foo() #0 { entry: %pp = alloca ptr, align 8 %w_cnt = alloca i32, align 4 diff --git a/test/test_suite/functions/splat_aarch64.c3t b/test/test_suite/functions/splat_aarch64.c3t index 902213b4b..3a3a1dd4c 100644 --- a/test/test_suite/functions/splat_aarch64.c3t +++ b/test/test_suite/functions/splat_aarch64.c3t @@ -20,7 +20,7 @@ fn void test() declare i32 @sum_us([2 x i64]) #0 -define void @splat_test() #0 { +define void @splat.test() #0 { entry: %varargslots = alloca [3 x i32], align 4 %taddr = alloca %"int[]", align 8 diff --git a/test/test_suite/functions/splat_mingw.c3t b/test/test_suite/functions/splat_mingw.c3t index bcedcd954..787c098cf 100644 --- a/test/test_suite/functions/splat_mingw.c3t +++ b/test/test_suite/functions/splat_mingw.c3t @@ -17,7 +17,7 @@ fn void test() declare i32 @sum_us(ptr align 8) #0 -define void @splat_test() #0 { +define void @splat.test() #0 { entry: %varargslots = alloca [3 x i32], align 4 %indirectarg = alloca %"int[]", align 8 diff --git a/test/test_suite/functions/static_vars.c3t b/test/test_suite/functions/static_vars.c3t index ac7205f65..bad77bb22 100644 --- a/test/test_suite/functions/static_vars.c3t +++ b/test/test_suite/functions/static_vars.c3t @@ -13,7 +13,7 @@ fn int test() @"test$x" = internal unnamed_addr global i32 1, align 4 @"test$y" = internal thread_local(localdynamic) unnamed_addr global i32 2, align 4 -define i32 @foo_test() #0 { +define i32 @foo.test() #0 { entry: %0 = load i32, ptr @"test$x", align 4 %add = add i32 %0, 1 diff --git a/test/test_suite/functions/test_regression.c3t b/test/test_suite/functions/test_regression.c3t index d18f0133a..d3b8f8c45 100644 --- a/test/test_suite/functions/test_regression.c3t +++ b/test/test_suite/functions/test_regression.c3t @@ -243,16 +243,16 @@ fn Type getValue(Blob blob) %List = type { i64, i64, ptr, ptr } %Foo = type { i32, i32 } -@"ct$test_Bobo" = linkonce constant %.introspect { i8 10, i64 20, i64 0, i64 6, [0 x i64] zeroinitializer }, align 8 -@"ct$test_Blob" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 -@"ct$test_Foor" = linkonce constant %.introspect { i8 11, i64 16, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 -@"ct$test_Foo2" = linkonce constant %.introspect { i8 10, i64 4, i64 0, i64 1, [0 x i64] zeroinitializer }, align 8 -@"ct$test_Foo" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 +@"ct$test.Bobo" = linkonce constant %.introspect { i8 10, i64 20, i64 0, i64 6, [0 x i64] zeroinitializer }, align 8 +@"ct$test.Blob" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 +@"ct$test.Foor" = linkonce constant %.introspect { i8 11, i64 16, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 +@"ct$test.Foo2" = linkonce constant %.introspect { i8 10, i64 4, i64 0, i64 1, [0 x i64] zeroinitializer }, align 8 + @"ct$int" = linkonce constant %.introspect { i8 2, i64 4, i64 0, i64 0, [0 x i64] zeroinitializer }, align 8 -@"ct$test_MyEnum" = linkonce constant { i8, i64, i64, i64, [3 x %"char[]"] } { i8 8, i64 4, i64 ptrtoint (ptr @"ct$int" to i64), i64 3, [3 x %"char[]"] [%"char[]" { ptr @.enum.0, i64 4 }, %"char[]" { ptr @.enum.1, i64 5 }, %"char[]" { ptr @.enum.2, i64 3 }] }, align 8 +@"ct$test.MyEnum" = linkonce constant { i8, i64, i64, i64, [3 x %"char[]"] } { i8 8, i64 4, i64 ptrtoint (ptr @"ct$int" to i64), i64 3, [3 x %"char[]"] [%"char[]" { ptr @.enum.0, i64 4 }, %"char[]" { ptr @.enum.1, i64 5 }, %"char[]" { ptr @.enum.2, i64 3 }] }, align 8 @"test_static$x" = internal unnamed_addr global i32 1, align 4 -define void @test_Foo2_printme(ptr %0) #0 { +define void @test.Foo2_printme(ptr %0) #0 { entry: %1 = getelementptr inbounds %Foo2, ptr %0, i32 0, i32 0 %2 = load i32, ptr %1, align 4 @@ -261,7 +261,7 @@ entry: } ; Function Attrs: nounwind -define i32 @test_Foo2_mutate(ptr %0) #0 { +define i32 @test.Foo2_mutate(ptr %0) #0 { entry: %1 = call i32 (ptr, ...) @printf(ptr @.str.22) %2 = getelementptr inbounds %Foo2, ptr %0, i32 0, i32 0 @@ -275,14 +275,14 @@ entry: declare i32 @printf(ptr, ...) #0 ; Function Attrs: nounwind -define void @test_helloWorld() #0 { +define void @test.helloWorld() #0 { entry: %0 = call i32 (ptr, ...) @printf(ptr @.str) ret void } ; Function Attrs: nounwind -define i32 @test_test_static() #0 { +define i32 @test.test_static() #0 { entry: %0 = load i32, ptr @"test_static$x", align 4 %add = add i32 %0, 1 @@ -294,7 +294,7 @@ entry: } ; Function Attrs: nounwind -define i32 @test_helo(double %0, ptr byval(%Bobo) align 8 %1) #0 { +define i32 @test.helo(double %0, ptr byval(%Bobo) align 8 %1) #0 { entry: %de = alloca [3 x i32], align 4 %c = alloca %Bobo, align 4 @@ -302,12 +302,12 @@ entry: call void @llvm.memcpy.p0.p0.i32(ptr align 4 %de, ptr align 4 @.__const, i32 12, i1 false) call void @llvm.memcpy.p0.p0.i32(ptr align 4 %c, ptr align 4 %1, i32 20, i1 false) call void @llvm.memcpy.p0.p0.i32(ptr align 8 %indirectarg, ptr align 4 %c, i32 20, i1 false) - %2 = call i32 @test_helo(double 1.000000e+00, ptr byval(%Bobo) align 8 %indirectarg) + %2 = call i32 @test.helo(double 1.000000e+00, ptr byval(%Bobo) align 8 %indirectarg) ret i32 1 } ; Function Attrs: nounwind -define i32 @test_test1(i32 %0, i32 %1) #0 { +define i32 @test.test1(i32 %0, i32 %1) #0 { entry: %a = alloca i32, align 4 store i32 %0, ptr %a, align 4 @@ -327,7 +327,7 @@ if.exit: ; preds = %entry } ; Function Attrs: nounwind -define i32 @test_sum_us(ptr %0, i64 %1) #0 { +define i32 @test.sum_us(ptr %0, i64 %1) #0 { entry: %x = alloca %"int[]", align 8 %sum = alloca i32, align 4 @@ -356,7 +356,7 @@ if.exit: ; preds = %entry %11 = add i64 %sub, 1 %size = sub i64 %11, 1 %ptroffset2 = getelementptr inbounds i32, ptr %9, i64 1 - %12 = call i32 @test_sum_us(ptr %ptroffset2, i64 %size) + %12 = call i32 @test.sum_us(ptr %ptroffset2, i64 %size) %add = add i32 %7, %12 %add3 = add i32 %4, %add store i32 %add3, ptr %sum, align 4 @@ -365,7 +365,7 @@ if.exit: ; preds = %entry } ; Function Attrs: nounwind -define i32 @test_sumd(ptr %0, i64 %1) #0 { +define i32 @test.sumd(ptr %0, i64 %1) #0 { entry: %x = alloca %"int[]", align 8 %sum = alloca i32, align 4 @@ -408,7 +408,7 @@ loop.exit: ; preds = %loop.cond } ; Function Attrs: nounwind -define void @test_main() #0 { +define void @test.main() #0 { entry: %list = alloca %LinkedList, align 8 %i = alloca i32, align 4 @@ -426,20 +426,20 @@ entry: %varargslots10 = alloca [1 x i32], align 4 %a1 = alloca ptr, align 8 %b2 = alloca ptr, align 8 - %0 = call i32 @test_test_static() - %1 = call i32 @test_test_static() - %2 = call i32 @test_test_static() - call void @hello_world_hello() + %0 = call i32 @test.test_static() + %1 = call i32 @test.test_static() + %2 = call i32 @test.test_static() + call void @hello_world.hello() call void @llvm.memset.p0.i64(ptr align 8 %list, i8 0, i64 32, i1 false) - call void @"std_collections_linkedlist$$int_LinkedList_push"(ptr %list, i32 10) - call void @"std_collections_linkedlist$$int_LinkedList_push"(ptr %list, i32 15) - call void @"std_collections_linkedlist$$int_LinkedList_push"(ptr %list, i32 30) + call void @"std_collections_linkedlist$$int.LinkedList_push"(ptr %list, i32 10) + call void @"std_collections_linkedlist$$int.LinkedList_push"(ptr %list, i32 15) + call void @"std_collections_linkedlist$$int.LinkedList_push"(ptr %list, i32 30) store i32 0, ptr %i, align 4 br label %loop.cond loop.cond: ; preds = %loop.body, %entry %3 = load i32, ptr %i, align 4 - %4 = call i64 @"std_collections_linkedlist$$int_LinkedList_len"(ptr %list) #3 + %4 = call i64 @"std_collections_linkedlist$$int.LinkedList_len"(ptr %list) #3 %uisitrunc = trunc i64 %4 to i32 %lt = icmp slt i32 %3, %uisitrunc br i1 %lt, label %loop.body, label %loop.exit @@ -448,7 +448,7 @@ loop.body: ; preds = %loop.cond %5 = load i32, ptr %i, align 4 %6 = load i32, ptr %i, align 4 %siuiext = sext i32 %6 to i64 - %7 = call i32 @"std_collections_linkedlist$$int_LinkedList_get"(ptr %list, i64 %siuiext) + %7 = call i32 @"std_collections_linkedlist$$int.LinkedList_get"(ptr %list, i64 %siuiext) %8 = call i32 (ptr, ...) @printf(ptr @.str.2, i32 %5, i32 %7) %9 = load i32, ptr %i, align 4 %add = add i32 %9, 1 @@ -456,22 +456,22 @@ loop.body: ; preds = %loop.cond br label %loop.cond loop.exit: ; preds = %loop.cond - call void @"std_collections_linkedlist$$int_LinkedList_free"(ptr %list) + call void @"std_collections_linkedlist$$int.LinkedList_free"(ptr %list) %10 = call i32 (ptr, ...) @printf(ptr @.str.3, i32 3) store i32 3, ptr %elements, align 4 %11 = call i32 (ptr, ...) @printf(ptr @.str.4) call void @llvm.memset.p0.i64(ptr align 8 %array, i8 0, i64 32, i1 false) - call void @"std_collections_list$$int_List_append"(ptr %array, i32 100) - call void @"std_collections_list$$int_List_append"(ptr %array, i32 200) - call void @"std_collections_list$$int_List_append"(ptr %array, i32 400) - call void @"std_collections_list$$int_List_push"(ptr %array, i32 600) #3 - call void @"std_collections_list$$int_List_insert_at"(ptr %array, i64 2, i32 300) + call void @"std_collections_list$$int.List_append"(ptr %array, i32 100) + call void @"std_collections_list$$int.List_append"(ptr %array, i32 200) + call void @"std_collections_list$$int.List_append"(ptr %array, i32 400) + call void @"std_collections_list$$int.List_push"(ptr %array, i32 600) #3 + call void @"std_collections_list$$int.List_insert_at"(ptr %array, i64 2, i32 300) store i32 0, ptr %i1, align 4 br label %loop.cond2 loop.cond2: ; preds = %loop.body5, %loop.exit %12 = load i32, ptr %i1, align 4 - %13 = call i64 @"std_collections_list$$int_List_len"(ptr %array) + %13 = call i64 @"std_collections_list$$int.List_len"(ptr %array) %uisitrunc3 = trunc i64 %13 to i32 %lt4 = icmp slt i32 %12, %uisitrunc3 br i1 %lt4, label %loop.body5, label %loop.exit8 @@ -480,7 +480,7 @@ loop.body5: ; preds = %loop.cond2 %14 = load i32, ptr %i1, align 4 %15 = load i32, ptr %i1, align 4 %siuiext6 = sext i32 %15 to i64 - %16 = call i32 @"std_collections_list$$int_List_get"(ptr %array, i64 %siuiext6) + %16 = call i32 @"std_collections_list$$int.List_get"(ptr %array, i64 %siuiext6) %17 = call i32 (ptr, ...) @printf(ptr @.str.5, i32 %14, i32 %16) %18 = load i32, ptr %i1, align 4 %add7 = add i32 %18, 1 @@ -488,20 +488,20 @@ loop.body5: ; preds = %loop.cond2 br label %loop.cond2 loop.exit8: ; preds = %loop.cond2 - call void @"std_collections_list$$int_List_free"(ptr %array) + call void @"std_collections_list$$int.List_free"(ptr %array) call void @llvm.memcpy.p0.p0.i32(ptr align 4 %a, ptr align 4 @.__const.6, i32 4, i1 false) call void @llvm.memcpy.p0.p0.i32(ptr align 8 %b, ptr align 8 @.__const.7, i32 8, i1 false) %19 = load i32, ptr %a, align 4 - %20 = call i32 @"test2$$int_getValue"(i32 %19) + %20 = call i32 @"test2$$int.getValue"(i32 %19) %21 = call i32 (ptr, ...) @printf(ptr @.str.8, i32 %20) %22 = load double, ptr %b, align 8 - %23 = call double @"test2$$double_getValue"(double %22) + %23 = call double @"test2$$double.getValue"(double %22) %24 = call i32 (ptr, ...) @printf(ptr @.str.9, double %23) - %25 = call i32 @"test2$$int_getMult"(i32 25) + %25 = call i32 @"test2$$int.getMult"(i32 25) %26 = call i32 (ptr, ...) @printf(ptr @.str.10, i32 %25) - %27 = call double @"test2$$double_getMult"(double 3.300000e+00) + %27 = call double @"test2$$double.getMult"(double 3.300000e+00) %28 = call i32 (ptr, ...) @printf(ptr @.str.11, double %27) - call void @test_helloWorld() + call void @test.helloWorld() %29 = getelementptr inbounds %Foo, ptr %ddx, i32 0, i32 0 store i32 0, ptr %29, align 4 %30 = getelementptr inbounds %Foo, ptr %ddx, i32 0, i32 1 @@ -509,7 +509,7 @@ loop.exit8: ; preds = %loop.cond2 store i32 3, ptr %fro, align 4 call void @llvm.memcpy.p0.p0.i32(ptr align 16 %x, ptr align 16 @.__const.12, i32 16, i1 false) %31 = load i32, ptr %fro, align 4 - %32 = call i32 @test_sum_us(ptr %x, i64 4) + %32 = call i32 @test.sum_us(ptr %x, i64 4) %33 = call i32 (ptr, ...) @printf(ptr @.str.13, i32 %32) %add9 = add i32 %31, %33 store i32 %add9, ptr %fro, align 4 @@ -519,13 +519,13 @@ loop.exit8: ; preds = %loop.cond2 %37 = insertvalue %"int[]" %36, i64 4, 1 store %"int[]" %37, ptr %z, align 8 call void @llvm.memcpy.p0.p0.i32(ptr align 4 %de, ptr align 4 @.__const.15, i32 12, i1 false) - %38 = call i32 @test_sum_us(ptr %x, i64 4) + %38 = call i32 @test.sum_us(ptr %x, i64 4) %39 = call i32 (ptr, ...) @printf(ptr @.str.16, i32 %38) %40 = getelementptr inbounds %"int[]", ptr %z, i32 0, i32 0 %lo = load ptr, ptr %40, align 8 %41 = getelementptr inbounds %"int[]", ptr %z, i32 0, i32 1 %hi = load i64, ptr %41, align 8 - %42 = call i32 @test_sum_us(ptr %lo, i64 %hi) + %42 = call i32 @test.sum_us(ptr %lo, i64 %hi) %43 = call i32 (ptr, ...) @printf(ptr @.str.17, i32 %42) %44 = getelementptr inbounds [4 x i32], ptr %varargslots, i64 0, i64 0 store i32 1, ptr %44, align 4 @@ -535,13 +535,13 @@ loop.exit8: ; preds = %loop.cond2 store i32 4, ptr %46, align 4 %47 = getelementptr inbounds [4 x i32], ptr %varargslots, i64 0, i64 3 store i32 5, ptr %47, align 4 - %48 = call i32 @test_sum_us(ptr %varargslots, i64 4) + %48 = call i32 @test.sum_us(ptr %varargslots, i64 4) %49 = call i32 (ptr, ...) @printf(ptr @.str.18, i32 %48) %50 = getelementptr inbounds [1 x i32], ptr %varargslots10, i64 0, i64 0 store i32 1, ptr %50, align 4 - %51 = call i32 @test_sum_us(ptr %varargslots10, i64 1) + %51 = call i32 @test.sum_us(ptr %varargslots10, i64 1) %52 = call i32 (ptr, ...) @printf(ptr @.str.19, i32 %51) - %53 = call i32 @test_sum_us(ptr null, i64 0) + %53 = call i32 @test.sum_us(ptr null, i64 0) %54 = call i32 (ptr, ...) @printf(ptr @.str.20, i32 %53) store ptr null, ptr %a1, align 8 store ptr null, ptr %b2, align 8 @@ -549,16 +549,16 @@ loop.exit8: ; preds = %loop.cond2 } // #expect: hello_world.ll -define void @hello_world_hello() +define void @hello_world.hello() entry: %0 = call i32 (ptr, ...) @printf(ptr @.str) - %1 = call double @"foo$$double_check"(double 1.110000e+01) + %1 = call double @"foo$$double.check"(double 1.110000e+01) %2 = call i32 (ptr, ...) @printf(ptr @.str.1, double %1) ret void // #expect: foo.double.ll -define double @"foo$$double_check"(double %0) +define double @"foo$$double.check"(double %0) entry: %fmul = fmul double %0, %0 ret double %fmul @@ -567,20 +567,20 @@ entry: // #expect: test2.int.ll %Blob = type { i32 } -@"test2$$int_argh" = local_unnamed_addr global i32 234, align 4 +@"test2$$int.argh" = local_unnamed_addr global i32 234, align 4 -define i32 @"test2$$int_getMult"(i32 %0) #0 { +define i32 @"test2$$int.getMult"(i32 %0) #0 { entry: %mul = mul i32 %0, %0 ret i32 %mul } -define i32 @"test2$$int_hello"() #0 { +define i32 @"test2$$int.hello"() #0 { entry: ret i32 1 } -define i32 @"test2$$int_getValue"(i32 %0) #0 { +define i32 @"test2$$int.getValue"(i32 %0) #0 { entry: %blob = alloca %Blob, align 4 store i32 %0, ptr %blob, align 4 @@ -592,18 +592,18 @@ entry: // #expect: test2.double.ll %Blob = type { double } -@"test2$$double_argh" = local_unnamed_addr global double 2.340000e+02, align 8 +@"test2$$double.argh" = local_unnamed_addr global double 2.340000e+02, align 8 -define double @"test2$$double_getMult"(double %0) +define double @"test2$$double.getMult"(double %0) entry: %fmul = fmul double %0, %0 ret double %fmul -define i32 @"test2$$double_hello"() +define i32 @"test2$$double.hello"() entry: ret i32 1 -define double @"test2$$double_getValue"(double %0) +define double @"test2$$double.getValue"(double %0) entry: %blob = alloca %Blob, align 8 store double %0, ptr %blob, align 8 diff --git a/test/test_suite/functions/test_regression_mingw.c3t b/test/test_suite/functions/test_regression_mingw.c3t index 8c67bcc7b..ea6989396 100644 --- a/test/test_suite/functions/test_regression_mingw.c3t +++ b/test/test_suite/functions/test_regression_mingw.c3t @@ -245,27 +245,27 @@ fn Type getValue(Blob blob) %List = type { i64, i64, ptr, ptr } %Foo = type { i32, i32 } -$"ct$test_Bobo" = comdat any +$"ct$test.Bobo" = comdat any -$"ct$test_Blob" = comdat any +$"ct$test.Blob" = comdat any -$"ct$test_Foor" = comdat any +$"ct$test.Foor" = comdat any -$"ct$test_Foo2" = comdat any +$"ct$test.Foo2" = comdat any -$"ct$test_Foo" = comdat any +$"ct$test.Foo" = comdat any $"ct$int" = comdat any -$"ct$test_MyEnum" = comdat any +$"ct$test.MyEnum" = comdat any -@"ct$test_Bobo" = linkonce constant %.introspect { i8 10, i64 20, i64 0, i64 6, [0 x i64] zeroinitializer }, comdat, align 8 -@"ct$test_Blob" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, comdat, align 8 -@"ct$test_Foor" = linkonce constant %.introspect { i8 11, i64 16, i64 0, i64 2, [0 x i64] zeroinitializer }, comdat, align 8 -@"ct$test_Foo2" = linkonce constant %.introspect { i8 10, i64 4, i64 0, i64 1, [0 x i64] zeroinitializer }, comdat, align 8 -@"ct$test_Foo" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, comdat, align 8 +@"ct$test.Bobo" = linkonce constant %.introspect { i8 10, i64 20, i64 0, i64 6, [0 x i64] zeroinitializer }, comdat, align 8 +@"ct$test.Blob" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, comdat, align 8 +@"ct$test.Foor" = linkonce constant %.introspect { i8 11, i64 16, i64 0, i64 2, [0 x i64] zeroinitializer }, comdat, align 8 +@"ct$test.Foo2" = linkonce constant %.introspect { i8 10, i64 4, i64 0, i64 1, [0 x i64] zeroinitializer }, comdat, align 8 +@"ct$test.Foo" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, comdat, align 8 @"ct$int" = linkonce constant %.introspect { i8 2, i64 4, i64 0, i64 0, [0 x i64] zeroinitializer }, comdat, align 8 -@"ct$test_MyEnum" = linkonce constant { i8, i64, i64, i64, [3 x %"char[]"] } { i8 8, i64 4, i64 ptrtoint (ptr @"ct$int" to i64), i64 3, [3 x %"char[]"] [%"char[]" { ptr @.enum.0, i64 4 }, %"char[]" { ptr @.enum.1, i64 5 }, %"char[]" { ptr @.enum.2, i64 3 }] }, comdat, align 8 +@"ct$test.MyEnum" = linkonce constant { i8, i64, i64, i64, [3 x %"char[]"] } { i8 8, i64 4, i64 ptrtoint (ptr @"ct$int" to i64), i64 3, [3 x %"char[]"] [%"char[]" { ptr @.enum.0, i64 4 }, %"char[]" { ptr @.enum.1, i64 5 }, %"char[]" { ptr @.enum.2, i64 3 }] }, comdat, align 8 @.str = private unnamed_addr constant [13 x i8] c"helloWorld!\0A\00", align 1 @"test_static$x" = internal unnamed_addr global i32 1, align 4 @.str.1 = private unnamed_addr constant [16 x i8] c"Test static %d\0A\00", align 1 @@ -293,7 +293,7 @@ $"ct$test_MyEnum" = comdat any @.str.22 = private unnamed_addr constant [9 x i8] c"Mutating\00", align 1 ; Function Attrs: nounwind -define void @test_Foo2_printme(ptr %0) #0 { +define void @test.Foo2_printme(ptr %0) #0 { entry: %1 = getelementptr inbounds %Foo2, ptr %0, i32 0, i32 0 %2 = load i32, ptr %1, align 4 @@ -302,7 +302,7 @@ entry: } ; Function Attrs: nounwind -define i32 @test_Foo2_mutate(ptr %0) #0 { +define i32 @test.Foo2_mutate(ptr %0) #0 { entry: %1 = call i32 (ptr, ...) @printf(ptr @.str.22) %2 = getelementptr inbounds %Foo2, ptr %0, i32 0, i32 0 @@ -316,14 +316,14 @@ entry: declare i32 @printf(ptr, ...) #0 ; Function Attrs: nounwind -define void @test_helloWorld() #0 { +define void @test.helloWorld() #0 { entry: %0 = call i32 (ptr, ...) @printf(ptr @.str) ret void } ; Function Attrs: nounwind -define i32 @test_test_static() #0 { +define i32 @test.test_static() #0 { entry: %0 = load i32, ptr @"test_static$x", align 4 %add = add i32 %0, 1 @@ -335,7 +335,7 @@ entry: } ; Function Attrs: nounwind -define i32 @test_helo(double %0, ptr align 4 %1) #0 { +define i32 @test.helo(double %0, ptr align 4 %1) #0 { entry: %de = alloca [3 x i32], align 4 %c = alloca %Bobo, align 4 @@ -343,12 +343,12 @@ entry: call void @llvm.memcpy.p0.p0.i32(ptr align 4 %de, ptr align 4 @.__const, i32 12, i1 false) call void @llvm.memcpy.p0.p0.i32(ptr align 4 %c, ptr align 4 %1, i32 20, i1 false) call void @llvm.memcpy.p0.p0.i32(ptr align 4 %indirectarg, ptr align 4 %c, i32 20, i1 false) - %2 = call i32 @test_helo(double 1.000000e+00, ptr align 4 %indirectarg) + %2 = call i32 @test.helo(double 1.000000e+00, ptr align 4 %indirectarg) ret i32 1 } ; Function Attrs: nounwind -define i32 @test_test1(i32 %0, i32 %1) #0 { +define i32 @test.test1(i32 %0, i32 %1) #0 { entry: %a = alloca i32, align 4 store i32 %0, ptr %a, align 4 @@ -368,7 +368,7 @@ if.exit: ; preds = %entry } ; Function Attrs: nounwind -define i32 @test_sum_us(ptr align 8 %0) #0 { +define i32 @test.sum_us(ptr align 8 %0) #0 { entry: %sum = alloca i32, align 4 %indirectarg = alloca %"int[]", align 8 @@ -397,7 +397,7 @@ if.exit: ; preds = %entry %11 = insertvalue %"int[]" undef, ptr %ptroffset1, 0 %12 = insertvalue %"int[]" %11, i64 %size, 1 store %"int[]" %12, ptr %indirectarg, align 8 - %13 = call i32 @test_sum_us(ptr align 8 %indirectarg) + %13 = call i32 @test.sum_us(ptr align 8 %indirectarg) %add = add i32 %6, %13 %add2 = add i32 %3, %add store i32 %add2, ptr %sum, align 4 @@ -406,7 +406,7 @@ if.exit: ; preds = %entry } ; Function Attrs: nounwind -define i32 @test_sumd(ptr align 8 %0) #0 { +define i32 @test.sumd(ptr align 8 %0) #0 { entry: %sum = alloca i32, align 4 %i = alloca i32, align 4 @@ -445,7 +445,7 @@ loop.exit: ; preds = %loop.cond } ; Function Attrs: nounwind -define void @test_main() #0 { +define void @test.main() #0 { entry: %list = alloca %LinkedList, align 8 %i = alloca i32, align 4 @@ -469,20 +469,20 @@ entry: %indirectarg15 = alloca %"int[]", align 8 %a1 = alloca ptr, align 8 %b2 = alloca ptr, align 8 - %0 = call i32 @test_test_static() - %1 = call i32 @test_test_static() - %2 = call i32 @test_test_static() - call void @hello_world_hello() + %0 = call i32 @test.test_static() + %1 = call i32 @test.test_static() + %2 = call i32 @test.test_static() + call void @hello_world.hello() call void @llvm.memset.p0.i64(ptr align 8 %list, i8 0, i64 32, i1 false) - call void @"std_collections_linkedlist$$int_LinkedList_push"(ptr %list, i32 10) - call void @"std_collections_linkedlist$$int_LinkedList_push"(ptr %list, i32 15) - call void @"std_collections_linkedlist$$int_LinkedList_push"(ptr %list, i32 30) + call void @"std_collections_linkedlist$$int.LinkedList_push"(ptr %list, i32 10) + call void @"std_collections_linkedlist$$int.LinkedList_push"(ptr %list, i32 15) + call void @"std_collections_linkedlist$$int.LinkedList_push"(ptr %list, i32 30) store i32 0, ptr %i, align 4 br label %loop.cond loop.cond: ; preds = %loop.body, %entry %3 = load i32, ptr %i, align 4 - %4 = call i64 @"std_collections_linkedlist$$int_LinkedList_len"(ptr %list) #3 + %4 = call i64 @"std_collections_linkedlist$$int.LinkedList_len"(ptr %list) #3 %uisitrunc = trunc i64 %4 to i32 %lt = icmp slt i32 %3, %uisitrunc br i1 %lt, label %loop.body, label %loop.exit @@ -491,7 +491,7 @@ loop.body: ; preds = %loop.cond %5 = load i32, ptr %i, align 4 %6 = load i32, ptr %i, align 4 %siuiext = sext i32 %6 to i64 - %7 = call i32 @"std_collections_linkedlist$$int_LinkedList_get"(ptr %list, i64 %siuiext) + %7 = call i32 @"std_collections_linkedlist$$int.LinkedList_get"(ptr %list, i64 %siuiext) %8 = call i32 (ptr, ...) @printf(ptr @.str.2, i32 %5, i32 %7) %9 = load i32, ptr %i, align 4 %add = add i32 %9, 1 @@ -499,22 +499,22 @@ loop.body: ; preds = %loop.cond br label %loop.cond loop.exit: ; preds = %loop.cond - call void @"std_collections_linkedlist$$int_LinkedList_free"(ptr %list) + call void @"std_collections_linkedlist$$int.LinkedList_free"(ptr %list) %10 = call i32 (ptr, ...) @printf(ptr @.str.3, i32 3) store i32 3, ptr %elements, align 4 %11 = call i32 (ptr, ...) @printf(ptr @.str.4) call void @llvm.memset.p0.i64(ptr align 8 %array, i8 0, i64 32, i1 false) - call void @"std_collections_list$$int_List_append"(ptr %array, i32 100) - call void @"std_collections_list$$int_List_append"(ptr %array, i32 200) - call void @"std_collections_list$$int_List_append"(ptr %array, i32 400) - call void @"std_collections_list$$int_List_push"(ptr %array, i32 600) #3 - call void @"std_collections_list$$int_List_insert_at"(ptr %array, i64 2, i32 300) + call void @"std_collections_list$$int.List_append"(ptr %array, i32 100) + call void @"std_collections_list$$int.List_append"(ptr %array, i32 200) + call void @"std_collections_list$$int.List_append"(ptr %array, i32 400) + call void @"std_collections_list$$int.List_push"(ptr %array, i32 600) #3 + call void @"std_collections_list$$int.List_insert_at"(ptr %array, i64 2, i32 300) store i32 0, ptr %i1, align 4 br label %loop.cond2 loop.cond2: ; preds = %loop.body5, %loop.exit %12 = load i32, ptr %i1, align 4 - %13 = call i64 @"std_collections_list$$int_List_len"(ptr %array) + %13 = call i64 @"std_collections_list$$int.List_len"(ptr %array) %uisitrunc3 = trunc i64 %13 to i32 %lt4 = icmp slt i32 %12, %uisitrunc3 br i1 %lt4, label %loop.body5, label %loop.exit8 @@ -523,7 +523,7 @@ loop.body5: ; preds = %loop.cond2 %14 = load i32, ptr %i1, align 4 %15 = load i32, ptr %i1, align 4 %siuiext6 = sext i32 %15 to i64 - %16 = call i32 @"std_collections_list$$int_List_get"(ptr %array, i64 %siuiext6) + %16 = call i32 @"std_collections_list$$int.List_get"(ptr %array, i64 %siuiext6) %17 = call i32 (ptr, ...) @printf(ptr @.str.5, i32 %14, i32 %16) %18 = load i32, ptr %i1, align 4 %add7 = add i32 %18, 1 @@ -531,20 +531,20 @@ loop.body5: ; preds = %loop.cond2 br label %loop.cond2 loop.exit8: ; preds = %loop.cond2 - call void @"std_collections_list$$int_List_free"(ptr %array) + call void @"std_collections_list$$int.List_free"(ptr %array) call void @llvm.memcpy.p0.p0.i32(ptr align 4 %a, ptr align 4 @.__const.6, i32 4, i1 false) call void @llvm.memcpy.p0.p0.i32(ptr align 8 %b, ptr align 8 @.__const.7, i32 8, i1 false) %19 = load i32, ptr %a, align 4 - %20 = call i32 @"test2$$int_getValue"(i32 %19) + %20 = call i32 @"test2$$int.getValue"(i32 %19) %21 = call i32 (ptr, ...) @printf(ptr @.str.8, i32 %20) %22 = load i64, ptr %b, align 8 - %23 = call double @"test2$$double_getValue"(i64 %22) + %23 = call double @"test2$$double.getValue"(i64 %22) %24 = call i32 (ptr, ...) @printf(ptr @.str.9, double %23) - %25 = call i32 @"test2$$int_getMult"(i32 25) + %25 = call i32 @"test2$$int.getMult"(i32 25) %26 = call i32 (ptr, ...) @printf(ptr @.str.10, i32 %25) - %27 = call double @"test2$$double_getMult"(double 3.300000e+00) + %27 = call double @"test2$$double.getMult"(double 3.300000e+00) %28 = call i32 (ptr, ...) @printf(ptr @.str.11, double %27) - call void @test_helloWorld() + call void @test.helloWorld() %29 = getelementptr inbounds %Foo, ptr %ddx, i32 0, i32 0 store i32 0, ptr %29, align 4 %30 = getelementptr inbounds %Foo, ptr %ddx, i32 0, i32 1 @@ -555,7 +555,7 @@ loop.exit8: ; preds = %loop.cond2 %32 = insertvalue %"int[]" undef, ptr %x, 0 %33 = insertvalue %"int[]" %32, i64 4, 1 store %"int[]" %33, ptr %indirectarg, align 8 - %34 = call i32 @test_sum_us(ptr align 8 %indirectarg) + %34 = call i32 @test.sum_us(ptr align 8 %indirectarg) %35 = call i32 (ptr, ...) @printf(ptr @.str.13, i32 %34) %add9 = add i32 %31, %35 store i32 %add9, ptr %fro, align 4 @@ -568,10 +568,10 @@ loop.exit8: ; preds = %loop.cond2 %40 = insertvalue %"int[]" undef, ptr %x, 0 %41 = insertvalue %"int[]" %40, i64 4, 1 store %"int[]" %41, ptr %indirectarg10, align 8 - %42 = call i32 @test_sum_us(ptr align 8 %indirectarg10) + %42 = call i32 @test.sum_us(ptr align 8 %indirectarg10) %43 = call i32 (ptr, ...) @printf(ptr @.str.16, i32 %42) call void @llvm.memcpy.p0.p0.i32(ptr align 8 %indirectarg11, ptr align 8 %z, i32 16, i1 false) - %44 = call i32 @test_sum_us(ptr align 8 %indirectarg11) + %44 = call i32 @test.sum_us(ptr align 8 %indirectarg11) %45 = call i32 (ptr, ...) @printf(ptr @.str.17, i32 %44) %46 = getelementptr inbounds [4 x i32], ptr %varargslots, i64 0, i64 0 store i32 1, ptr %46, align 4 @@ -584,17 +584,17 @@ loop.exit8: ; preds = %loop.cond2 %50 = insertvalue %"int[]" undef, ptr %varargslots, 0 %51 = insertvalue %"int[]" %50, i64 4, 1 store %"int[]" %51, ptr %indirectarg12, align 8 - %52 = call i32 @test_sum_us(ptr align 8 %indirectarg12) + %52 = call i32 @test.sum_us(ptr align 8 %indirectarg12) %53 = call i32 (ptr, ...) @printf(ptr @.str.18, i32 %52) %54 = getelementptr inbounds [1 x i32], ptr %varargslots13, i64 0, i64 0 store i32 1, ptr %54, align 4 %55 = insertvalue %"int[]" undef, ptr %varargslots13, 0 %56 = insertvalue %"int[]" %55, i64 1, 1 store %"int[]" %56, ptr %indirectarg14, align 8 - %57 = call i32 @test_sum_us(ptr align 8 %indirectarg14) + %57 = call i32 @test.sum_us(ptr align 8 %indirectarg14) %58 = call i32 (ptr, ...) @printf(ptr @.str.19, i32 %57) store %"int[]" zeroinitializer, ptr %indirectarg15, align 8 - %59 = call i32 @test_sum_us(ptr align 8 %indirectarg15) + %59 = call i32 @test.sum_us(ptr align 8 %indirectarg15) %60 = call i32 (ptr, ...) @printf(ptr @.str.20, i32 %59) store ptr null, ptr %a1, align 8 store ptr null, ptr %b2, align 8 @@ -603,43 +603,43 @@ loop.exit8: ; preds = %loop.cond2 declare void @llvm.memcpy.p0.p0.i32(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i32, i1 immarg) #1 -declare void @hello_world_hello() +declare void @hello_world.hello() #0 declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #2 -declare void @"std_collections_linkedlist$$int_LinkedList_push"(ptr, i32) +declare void @"std_collections_linkedlist$$int.LinkedList_push"(ptr, i32) #0 -declare i64 @"std_collections_linkedlist$$int_LinkedList_len"(ptr) +declare i64 @"std_collections_linkedlist$$int.LinkedList_len"(ptr) #0 -declare i32 @"std_collections_linkedlist$$int_LinkedList_get"(ptr, i64) +declare i32 @"std_collections_linkedlist$$int.LinkedList_get"(ptr, i64) #0 -declare void @"std_collections_linkedlist$$int_LinkedList_free"(ptr) +declare void @"std_collections_linkedlist$$int.LinkedList_free"(ptr) #0 -declare void @"std_collections_list$$int_List_append"(ptr, i32) +declare void @"std_collections_list$$int.List_append"(ptr, i32) #0 -declare void @"std_collections_list$$int_List_push"(ptr, i32) +declare void @"std_collections_list$$int.List_push"(ptr, i32) #0 -declare void @"std_collections_list$$int_List_insert_at"(ptr, i64, i32) +declare void @"std_collections_list$$int.List_insert_at"(ptr, i64, i32) #0 -declare i64 @"std_collections_list$$int_List_len"(ptr) +declare i64 @"std_collections_list$$int.List_len"(ptr) #0 -declare i32 @"std_collections_list$$int_List_get"(ptr, i64) +declare i32 @"std_collections_list$$int.List_get"(ptr, i64) #0 -declare void @"std_collections_list$$int_List_free"(ptr) +declare void @"std_collections_list$$int.List_free"(ptr) #0 // #expect: hello_world.ll -define void @hello_world_hello() #0 { +define void @hello_world.hello() #0 { entry: %0 = call i32 (ptr, ...) @printf(ptr @.str) - %1 = call double @"foo$$double_check"(double 1.110000e+01) + %1 = call double @"foo$$double.check"(double 1.110000e+01) %2 = call i32 (ptr, ...) @printf(ptr @.str.1, double %1) ret void } // #expect: foo.double.ll -define double @"foo$$double_check"(double %0) +define double @"foo$$double.check"(double %0) entry: %fmul = fmul double %0, %0 ret double %fmul @@ -648,19 +648,19 @@ entry: // #expect: test2.int.ll %Blob = type { i32 } -@"test2$$int_argh" = local_unnamed_addr global i32 234, align 4 +@"test2$$int.argh" = local_unnamed_addr global i32 234, align 4 -define i32 @"test2$$int_getMult"(i32 %0) +define i32 @"test2$$int.getMult"(i32 %0) entry: %mul = mul i32 %0, %0 ret i32 %mul -define i32 @"test2$$int_hello"() +define i32 @"test2$$int.hello"() entry: ret i32 1 } -define i32 @"test2$$int_getValue"(i32 %0) +define i32 @"test2$$int.getValue"(i32 %0) entry: %blob = alloca %Blob, align 4 store i32 %0, ptr %blob, align 4 @@ -672,19 +672,19 @@ entry: // #expect: test2.double.ll %Blob = type { double } -@"test2$$double_argh" = local_unnamed_addr global double 2.340000e+02, align 8 +@"test2$$double.argh" = local_unnamed_addr global double 2.340000e+02, align 8 -define double @"test2$$double_getMult"(double %0) +define double @"test2$$double.getMult"(double %0) entry: %fmul = fmul double %0, %0 ret double %fmul -define i32 @"test2$$double_hello"() +define i32 @"test2$$double.hello"() entry: ret i32 1 -define double @"test2$$double_getValue"(i64 %0) +define double @"test2$$double.getValue"(i64 %0) entry: %blob = alloca %Blob, align 8 store i64 %0, ptr %blob, align 8 diff --git a/test/test_suite/functions/typeless_varargs.c3t b/test/test_suite/functions/typeless_varargs.c3t index 08b18edd2..e527f4a6c 100644 --- a/test/test_suite/functions/typeless_varargs.c3t +++ b/test/test_suite/functions/typeless_varargs.c3t @@ -24,7 +24,7 @@ fn int main() @"ct$int" = linkonce constant %.introspect { i8 2, i64 4, i64 0, i64 0, [0 x i64] zeroinitializer }, align 8 -define void @test_retest(ptr %0, i64 %1) #0 { +define void @test.retest(ptr %0, i64 %1) #0 { entry: %foo = alloca %"variant[]", align 8 store ptr %0, ptr %foo, align 8 @@ -34,11 +34,11 @@ entry: %lo = load ptr, ptr %2, align 8 %3 = getelementptr inbounds %"variant[]", ptr %foo, i32 0, i32 1 %hi = load i64, ptr %3, align 8 - call void @test_test(ptr %lo, i64 %hi) + call void @test.test(ptr %lo, i64 %hi) ret void } -define void @test_test(ptr %0, i64 %1) #0 { +define void @test.test(ptr %0, i64 %1) #0 { entry: %foo = alloca %"variant[]", align 8 store ptr %0, ptr %foo, align 8 @@ -67,12 +67,12 @@ entry: %1 = insertvalue %variant %0, i64 ptrtoint (ptr @"ct$int" to i64), 1 %2 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %1, ptr %2, align 16 - call void @test_test(ptr %varargslots, i64 1) + call void @test.test(ptr %varargslots, i64 1) store i32 1, ptr %taddr2, align 4 %3 = insertvalue %variant undef, ptr %taddr2, 0 %4 = insertvalue %variant %3, i64 ptrtoint (ptr @"ct$int" to i64), 1 %5 = getelementptr inbounds [1 x %variant], ptr %varargslots1, i64 0, i64 0 store %variant %4, ptr %5, align 16 - call void @test_retest(ptr %varargslots1, i64 1) + call void @test.retest(ptr %varargslots1, i64 1) ret i32 1 } \ No newline at end of file diff --git a/test/test_suite/functions/varargs.c3t b/test/test_suite/functions/varargs.c3t index 1147930f1..0db8893de 100644 --- a/test/test_suite/functions/varargs.c3t +++ b/test/test_suite/functions/varargs.c3t @@ -17,7 +17,7 @@ fn void test() /* #expect: varargs.ll -define void @varargs_test() #0 { +define void @varargs.test() #0 { entry: %x1 = alloca i8, align 1 %b = alloca i8, align 1 diff --git a/test/test_suite/functions/varargs_followed_by_named.c3t b/test/test_suite/functions/varargs_followed_by_named.c3t index 58b8ddb47..bb953769e 100644 --- a/test/test_suite/functions/varargs_followed_by_named.c3t +++ b/test/test_suite/functions/varargs_followed_by_named.c3t @@ -22,7 +22,7 @@ fn void main() /* #expect: foo.ll -define void @foo_test(i32 %0, ptr %1, i64 %2, i32 %3) #0 { +define void @foo.test(i32 %0, ptr %1, i64 %2, i32 %3) #0 { entry: %y = alloca %"int[]", align 8 store ptr %1, ptr %y, align 8 @@ -40,7 +40,7 @@ entry: } ; Function Attrs: nounwind -define void @foo_test2(i32 %0, ptr %1, i64 %2, i32 %3) #0 { +define void @foo.test2(i32 %0, ptr %1, i64 %2, i32 %3) #0 { entry: %y = alloca %"variant[]", align 8 store ptr %1, ptr %y, align 8 @@ -54,7 +54,7 @@ entry: } ; Function Attrs: nounwind -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %varargslots = alloca [2 x i32], align 4 %varargslots1 = alloca [2 x %variant], align 16 @@ -68,7 +68,7 @@ entry: store i32 4, ptr %0, align 4 %1 = getelementptr inbounds [2 x i32], ptr %varargslots, i64 0, i64 1 store i32 5, ptr %1, align 4 - call void @foo_test(i32 3, ptr %varargslots, i64 2, i32 123) + call void @foo.test(i32 3, ptr %varargslots, i64 2, i32 123) store i32 4, ptr %taddr, align 4 %2 = insertvalue %variant undef, ptr %taddr, 0 %3 = insertvalue %variant %2, i64 ptrtoint (ptr @"ct$int" to i64), 1 @@ -79,12 +79,12 @@ entry: %6 = insertvalue %variant %5, i64 ptrtoint (ptr @"ct$int" to i64), 1 %7 = getelementptr inbounds [2 x %variant], ptr %varargslots1, i64 0, i64 1 store %variant %6, ptr %7, align 16 - call void @foo_test2(i32 3, ptr %varargslots1, i64 2, i32 123) + call void @foo.test2(i32 3, ptr %varargslots1, i64 2, i32 123) %8 = getelementptr inbounds [2 x i32], ptr %varargslots3, i64 0, i64 0 store i32 4, ptr %8, align 4 %9 = getelementptr inbounds [2 x i32], ptr %varargslots3, i64 0, i64 1 store i32 5, ptr %9, align 4 - call void @foo_test(i32 3, ptr %varargslots3, i64 2, i32 2) + call void @foo.test(i32 3, ptr %varargslots3, i64 2, i32 2) store i32 4, ptr %taddr5, align 4 %10 = insertvalue %variant undef, ptr %taddr5, 0 %11 = insertvalue %variant %10, i64 ptrtoint (ptr @"ct$int" to i64), 1 @@ -95,6 +95,6 @@ entry: %14 = insertvalue %variant %13, i64 ptrtoint (ptr @"ct$int" to i64), 1 %15 = getelementptr inbounds [2 x %variant], ptr %varargslots4, i64 0, i64 1 store %variant %14, ptr %15, align 16 - call void @foo_test2(i32 3, ptr %varargslots4, i64 2, i32 2) + call void @foo.test2(i32 3, ptr %varargslots4, i64 2, i32 2) ret void } \ No newline at end of file diff --git a/test/test_suite/generic/enum_set_test.c3t b/test/test_suite/generic/enum_set_test.c3t index 2751b2d3e..75fa8bad7 100644 --- a/test/test_suite/generic/enum_set_test.c3t +++ b/test/test_suite/generic/enum_set_test.c3t @@ -27,7 +27,7 @@ fn void main() /* #expect: test.ll -define void @test_main() #0 { +define void @test.main() #0 { entry: %set = alloca i32, align 4 %retparam = alloca i64, align 8 @@ -47,47 +47,47 @@ entry: %varargslots11 = alloca [1 x %variant], align 16 %taddr12 = alloca i8, align 1 store i32 0, ptr %set, align 4 - %0 = call i8 @"std_collections_enumset$$test_Abc_EnumSet_has"(ptr %set, i32 1) + %0 = call i8 @"std_collections_enumset$$test.Abc.EnumSet_has"(ptr %set, i32 1) store i8 %0, ptr %taddr, align 1 %1 = insertvalue %variant undef, ptr %taddr, 0 %2 = insertvalue %variant %1, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %3 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %2, ptr %3, align 16 - %4 = call i64 @std_io_printf(ptr %retparam, ptr @.str, i64 14, ptr %varargslots, i64 1) - call void @"std_collections_enumset$$test_Abc_EnumSet_add"(ptr %set, i32 0) - %5 = call i8 @"std_collections_enumset$$test_Abc_EnumSet_has"(ptr %set, i32 1) + %4 = call i64 @std_io.printf(ptr %retparam, ptr @.str, i64 14, ptr %varargslots, i64 1) + call void @"std_collections_enumset$$test.Abc.EnumSet_add"(ptr %set, i32 0) + %5 = call i8 @"std_collections_enumset$$test.Abc.EnumSet_has"(ptr %set, i32 1) store i8 %5, ptr %taddr3, align 1 %6 = insertvalue %variant undef, ptr %taddr3, 0 %7 = insertvalue %variant %6, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %8 = getelementptr inbounds [1 x %variant], ptr %varargslots2, i64 0, i64 0 store %variant %7, ptr %8, align 16 - %9 = call i64 @std_io_printf(ptr %retparam1, ptr @.str.1, i64 14, ptr %varargslots2, i64 1) - call void @"std_collections_enumset$$test_Abc_EnumSet_add"(ptr %set, i32 1) - %10 = call i8 @"std_collections_enumset$$test_Abc_EnumSet_has"(ptr %set, i32 1) + %9 = call i64 @std_io.printf(ptr %retparam1, ptr @.str.1, i64 14, ptr %varargslots2, i64 1) + call void @"std_collections_enumset$$test.Abc.EnumSet_add"(ptr %set, i32 1) + %10 = call i8 @"std_collections_enumset$$test.Abc.EnumSet_has"(ptr %set, i32 1) store i8 %10, ptr %taddr6, align 1 %11 = insertvalue %variant undef, ptr %taddr6, 0 %12 = insertvalue %variant %11, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %13 = getelementptr inbounds [1 x %variant], ptr %varargslots5, i64 0, i64 0 store %variant %12, ptr %13, align 16 - %14 = call i64 @std_io_printf(ptr %retparam4, ptr @.str.2, i64 14, ptr %varargslots5, i64 1) + %14 = call i64 @std_io.printf(ptr %retparam4, ptr @.str.2, i64 14, ptr %varargslots5, i64 1) store i32 0, ptr %set2, align 4 %15 = load i32, ptr %set, align 4 - call void @"std_collections_enumset$$test_Abc_EnumSet_add_all"(ptr %set2, i32 %15) - %16 = call i8 @"std_collections_enumset$$test_Abc_EnumSet_has"(ptr %set2, i32 1) + call void @"std_collections_enumset$$test.Abc.EnumSet_add_all"(ptr %set2, i32 %15) + %16 = call i8 @"std_collections_enumset$$test.Abc.EnumSet_has"(ptr %set2, i32 1) store i8 %16, ptr %taddr9, align 1 %17 = insertvalue %variant undef, ptr %taddr9, 0 %18 = insertvalue %variant %17, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %19 = getelementptr inbounds [1 x %variant], ptr %varargslots8, i64 0, i64 0 store %variant %18, ptr %19, align 16 - %20 = call i64 @std_io_printf(ptr %retparam7, ptr @.str.3, i64 14, ptr %varargslots8, i64 1) + %20 = call i64 @std_io.printf(ptr %retparam7, ptr @.str.3, i64 14, ptr %varargslots8, i64 1) %21 = load i32, ptr %set2, align 4 - call void @"std_collections_enumset$$test_Abc_EnumSet_remove_all"(ptr %set, i32 %21) - %22 = call i8 @"std_collections_enumset$$test_Abc_EnumSet_has"(ptr %set, i32 1) + call void @"std_collections_enumset$$test.Abc.EnumSet_remove_all"(ptr %set, i32 %21) + %22 = call i8 @"std_collections_enumset$$test.Abc.EnumSet_has"(ptr %set, i32 1) store i8 %22, ptr %taddr12, align 1 %23 = insertvalue %variant undef, ptr %taddr12, 0 %24 = insertvalue %variant %23, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %25 = getelementptr inbounds [1 x %variant], ptr %varargslots11, i64 0, i64 0 store %variant %24, ptr %25, align 16 - %26 = call i64 @std_io_printf(ptr %retparam10, ptr @.str.4, i64 14, ptr %varargslots11, i64 1) + %26 = call i64 @std_io.printf(ptr %retparam10, ptr @.str.4, i64 14, ptr %varargslots11, i64 1) ret void } diff --git a/test/test_suite/generic/generic_idents.c3t b/test/test_suite/generic/generic_idents.c3t index 9b8e5acc3..d3e56e51b 100644 --- a/test/test_suite/generic/generic_idents.c3t +++ b/test/test_suite/generic/generic_idents.c3t @@ -28,13 +28,13 @@ fn double getIt2(double i) /* #expect: gen.int.ll -define i32 @"gen$$int_mult"(i32 %0) #0 { +define i32 @"gen$$int.mult"(i32 %0) #0 { entry: %mul = mul i32 %0, %0 ret i32 %mul } -define i32 @"gen$$int_addMult"(i32 %0, i32 %1, i32 %2) #0 { +define i32 @"gen$$int.addMult"(i32 %0, i32 %1, i32 %2) #0 { entry: %mul = mul i32 %0, %1 %add = add i32 %mul, %2 @@ -44,25 +44,25 @@ entry: // #expect: test.ll -define i32 @test_getIt(i32 %0) #0 { +define i32 @test.getIt(i32 %0) #0 { entry: - %1 = call i32 @"gen$$int_mult"(i32 %0) + %1 = call i32 @"gen$$int.mult"(i32 %0) %add = add i32 %1, 1 ret i32 %add } -define double @test_getIt2(double %0) #0 { +define double @test.getIt2(double %0) #0 { entry: - %1 = call double @"gen$$double_addMult"(double %0, double 2.000000e+00, double 3.000000e+00) + %1 = call double @"gen$$double.addMult"(double %0, double 2.000000e+00, double 3.000000e+00) ret double %1 } -declare i32 @"gen$$int_mult"(i32) +declare i32 @"gen$$int.mult"(i32) -declare double @"gen$$double_addMult"(double, double, double) +declare double @"gen$$double.addMult"(double, double, double) // #expect: gen.double.ll -define double @"gen$$double_addMult"(double %0, double %1, double %2) +define double @"gen$$double.addMult"(double %0, double %1, double %2) %3 = call double @llvm.fmuladd.f64(double %0, double %1, double %2) ret double %3 diff --git a/test/test_suite/generic/generic_num.c3t b/test/test_suite/generic/generic_num.c3t index 1524c088c..b0615670f 100644 --- a/test/test_suite/generic/generic_num.c3t +++ b/test/test_suite/generic/generic_num.c3t @@ -19,18 +19,18 @@ fn void main() /* #expect: test.ll -define void @test_main() #0 { +define void @test.main() #0 { entry: %retparam = alloca i64, align 8 %varargslots = alloca [1 x %variant], align 16 %taddr = alloca i32, align 4 - %0 = call i32 @"hello$$int._123_x"(i32 4) + %0 = call i32 @"hello$$int._123.x"(i32 4) store i32 %0, ptr %taddr, align 4 %1 = insertvalue %variant undef, ptr %taddr, 0 %2 = insertvalue %variant %1, i64 ptrtoint (ptr @"ct$int" to i64), 1 %3 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %2, ptr %3, align 16 - %4 = call i64 @std_io_printfn(ptr %retparam, ptr @.str, i64 2, ptr %varargslots, i64 1) + %4 = call i64 @std_io.printfn(ptr %retparam, ptr @.str, i64 2, ptr %varargslots, i64 1) ret void } diff --git a/test/test_suite/generic/generic_recursion.c3t b/test/test_suite/generic/generic_recursion.c3t index 1ddb50dda..8bd0e12f2 100644 --- a/test/test_suite/generic/generic_recursion.c3t +++ b/test/test_suite/generic/generic_recursion.c3t @@ -18,4 +18,4 @@ TreeNode abc; %TreeNode = type { ptr, ptr, %List } %List = type { i64, i64, ptr, ptr } -@test_abc = local_unnamed_addr global %TreeNode zeroinitializer, align 8 +@test.abc = local_unnamed_addr global %TreeNode zeroinitializer, align 8 diff --git a/test/test_suite/globals/global_align.c3t b/test/test_suite/globals/global_align.c3t index d53034854..67c16ba8f 100644 --- a/test/test_suite/globals/global_align.c3t +++ b/test/test_suite/globals/global_align.c3t @@ -11,12 +11,12 @@ fn void test() // #expect: abc.ll -@abc_foo = local_unnamed_addr global i32 0, align 32 +@abc.foo = local_unnamed_addr global i32 0, align 32 -define void @abc_test() #0 { +define void @abc.test() #0 { entry: %x = alloca i32, align 4 - %0 = load i32, ptr @abc_foo, align 32 + %0 = load i32, ptr @abc.foo, align 32 store i32 %0, ptr %x, align 4 ret void } diff --git a/test/test_suite/globals/global_no_init.c3t b/test/test_suite/globals/global_no_init.c3t index 67d82b768..118996d65 100644 --- a/test/test_suite/globals/global_no_init.c3t +++ b/test/test_suite/globals/global_no_init.c3t @@ -18,15 +18,15 @@ fn void main() /* #expect: test.ll -@test_z = local_unnamed_addr global i32 undef, align 4 -@test_y = local_unnamed_addr global %Abc undef, align 4 -@test_a = local_unnamed_addr global i32 0, align 4 -@test_b = local_unnamed_addr global i32 0, align 4 -@test_c = local_unnamed_addr global i32 0, align 4 -@test_x1 = local_unnamed_addr global i32 undef, align 4 -@test_y1 = local_unnamed_addr global i32 undef, align 4 -@test_w = thread_local local_unnamed_addr global i32 0, align 4 -@test_v = thread_local local_unnamed_addr global i32 0, align 4 +@test.z = local_unnamed_addr global i32 undef, align 4 +@test.y = local_unnamed_addr global %Abc undef, align 4 +@test.a = local_unnamed_addr global i32 0, align 4 +@test.b = local_unnamed_addr global i32 0, align 4 +@test.c = local_unnamed_addr global i32 0, align 4 +@test.x1 = local_unnamed_addr global i32 undef, align 4 +@test.y1 = local_unnamed_addr global i32 undef, align 4 +@test.w = thread_local local_unnamed_addr global i32 0, align 4 +@test.v = thread_local local_unnamed_addr global i32 0, align 4 -%0 = load i32, ptr @test_y, align 4 -store i32 %0, ptr @test_z, align 4 +%0 = load i32, ptr @test.y, align 4 +store i32 %0, ptr @test.z, align 4 diff --git a/test/test_suite/import/access_other_module.c3t b/test/test_suite/import/access_other_module.c3t index 02716f8a2..118976d07 100644 --- a/test/test_suite/import/access_other_module.c3t +++ b/test/test_suite/import/access_other_module.c3t @@ -9,14 +9,14 @@ fn void main() /* #expect: foo.ll -@libc_EXIT_SUCCESS = external constant i32, align 4 +@libc.EXIT_SUCCESS = external constant i32, align 4 -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %foekf = alloca ptr, align 8 %xok = alloca ptr, align 8 store ptr @printf, ptr %foekf, align 8 - store ptr @libc_EXIT_SUCCESS, ptr %xok, align 8 + store ptr @libc.EXIT_SUCCESS, ptr %xok, align 8 ret void } diff --git a/test/test_suite/initializer_lists/fasta.c3t b/test/test_suite/initializer_lists/fasta.c3t index 8e7096507..866227e09 100644 --- a/test/test_suite/initializer_lists/fasta.c3t +++ b/test/test_suite/initializer_lists/fasta.c3t @@ -111,35 +111,35 @@ fn int main(int argc, char **argv) %"char[]" = type { ptr, i64 } %"double[]" = type { ptr, i64 } -@fasta_IM = local_unnamed_addr constant i32 139968, align 4 -@fasta_IA = local_unnamed_addr constant i32 3877, align 4 -@fasta_IC = local_unnamed_addr constant i32 29573, align 4 -@fasta_SEED = local_unnamed_addr constant i32 42, align 4 -@fasta_seed = local_unnamed_addr global i32 42, align 4 +@fasta.IM = local_unnamed_addr constant i32 139968, align 4 +@fasta.IA = local_unnamed_addr constant i32 3877, align 4 +@fasta.IC = local_unnamed_addr constant i32 29573, align 4 +@fasta.SEED = local_unnamed_addr constant i32 42, align 4 +@fasta.seed = local_unnamed_addr global i32 42, align 4 @.str = private unnamed_addr constant [288 x i8] c"GGCCGGGCGCGGTGGCTCACGCCTGTAATCCCAGCACTTTGGGAGGCCGAGGCGGGCGGATCACCTGAGGTCAGGAGTTCGAGACCAGCCTGGCCAACATGGTGAAACCCCGTCTCTACTAAAAATACAAAAATTAGCCGGGCGTGGTGGCGCGCGCCTGTAATCCCAGCTACTCGGGAGGCTGAGGCAGGAGAATCGCTTGAACCCGGGAGGCGGAGGTTGCAGTGAGCCGAGATCGCGCCACTGCACTCCAGCCTGGGCGACAGAGCGAGACTCCGTCTCAAAAA\00", align 1 -@fasta_alu = protected unnamed_addr global %"char[]" { ptr @.str, i64 287 }, align 8 +@fasta.alu = protected unnamed_addr global %"char[]" { ptr @.str, i64 287 }, align 8 @.str.11 = private unnamed_addr constant [16 x i8] c"acgtBDHKMNRSVWY\00", align 1 -@fasta_iub = local_unnamed_addr global %"char[]" { ptr @.str.11, i64 15 }, align 8 +@fasta.iub = local_unnamed_addr global %"char[]" { ptr @.str.11, i64 15 }, align 8 @.taddr = private global [15 x double] [double 2.700000e-01, double 1.200000e-01, double 1.200000e-01, double 2.700000e-01, double 2.000000e-02, double 2.000000e-02, double 2.000000e-02, double 2.000000e-02, double 2.000000e-02, double 2.000000e-02, double 2.000000e-02, double 2.000000e-02, double 2.000000e-02, double 2.000000e-02, double 2.000000e-02], align 8 -@fasta_iub_p = local_unnamed_addr global %"double[]" { ptr @.taddr, i64 15 }, align 8 +@fasta.iub_p = local_unnamed_addr global %"double[]" { ptr @.taddr, i64 15 }, align 8 @.str.12 = private unnamed_addr constant [5 x i8] c"acgt\00", align 1 -@fasta_homosapiens = local_unnamed_addr global %"char[]" { ptr @.str.12, i64 4 }, align 8 +@fasta.homosapiens = local_unnamed_addr global %"char[]" { ptr @.str.12, i64 4 }, align 8 @.taddr.13 = private global [4 x double] [double 0x3FD3639D20BAEB5B, double 0x3FC957AE3DCD561B, double 0x3FC9493AEAB6C2BF, double 0x3FD34BEE4B030838], align 8 -@fasta_homosapiens_p = local_unnamed_addr global %"double[]" { ptr @.taddr.13, i64 4 }, align 8 -@fasta_LINELEN = local_unnamed_addr constant i32 60, align 4 +@fasta.homosapiens_p = local_unnamed_addr global %"double[]" { ptr @.taddr.13, i64 4 }, align 8 +@fasta.LINELEN = local_unnamed_addr constant i32 60, align 4 @.str.14 = private unnamed_addr constant [23 x i8] c">ONE Homo sapiens alu\0A\00", align 1 @.str.15 = private unnamed_addr constant [26 x i8] c">TWO IUB ambiguity codes\0A\00", align 1 @.str.16 = private unnamed_addr constant [31 x i8] c">THREE Homo sapiens frequency\0A\00", align 1 ; Function Attrs: nounwind -define float @fasta_fasta_rand(float %0) #0 { +define float @fasta.fasta_rand(float %0) #0 { entry: - %1 = load i32, ptr @fasta_seed, align 4 + %1 = load i32, ptr @fasta.seed, align 4 %mul = mul i32 %1, 3877 %add = add i32 %mul, 29573 %umod = urem i32 %add, 139968 - store i32 %umod, ptr @fasta_seed, align 4 - %2 = load i32, ptr @fasta_seed, align 4 + store i32 %umod, ptr @fasta.seed, align 4 + %2 = load i32, ptr @fasta.seed, align 4 %uifp = uitofp i32 %2 to float %fmul = fmul float %0, %uifp %fdiv = fdiv float %fmul, 1.399680e+05 @@ -156,7 +156,7 @@ declare i32 @printf(ptr, ...) #0 declare void @putchar(i32) #0 ; Function Attrs: nounwind -define void @fasta_repeat_fasta(ptr %0, i64 %1, i32 %2) #0 { +define void @fasta.repeat_fasta(ptr %0, i64 %1, i32 %2) #0 { entry: %seq = alloca %"char[]", align 8 %len = alloca i64, align 8 @@ -216,7 +216,7 @@ if.exit5: ; preds = %if.then4, %loop.exi } ; Function Attrs: nounwind -define void @fasta_random_fasta(ptr %0, i64 %1, ptr %2, i64 %3, i32 %4) #0 { +define void @fasta.random_fasta(ptr %0, i64 %1, ptr %2, i64 %3, i32 %4) #0 { entry: %symb = alloca %"char[]", align 8 %probability = alloca %"double[]", align 8 @@ -249,7 +249,7 @@ loop.cond: ; preds = %if.exit11, %entry br i1 %lt, label %loop.body, label %loop.exit13 loop.body: ; preds = %loop.cond - %12 = call float @fasta_fasta_rand(float 1.000000e+00) + %12 = call float @fasta.fasta_rand(float 1.000000e+00) %fpfpext = fpext float %12 to double store double %fpfpext, ptr %v, align 8 store i32 0, ptr %j, align 4 @@ -340,26 +340,26 @@ if.then: ; preds = %entry if.exit: ; preds = %if.then, %entry %4 = call i32 (ptr, ...) @printf(ptr @.str.14) - %lo = load ptr, ptr @fasta_alu, align 8 - %hi = load i64, ptr getelementptr inbounds (%"char[]", ptr @fasta_alu, i32 0, i32 1), align 8 + %lo = load ptr, ptr @fasta.alu, align 8 + %hi = load i64, ptr getelementptr inbounds (%"char[]", ptr @fasta.alu, i32 0, i32 1), align 8 %5 = load i32, ptr %n, align 4 %mul = mul i32 %5, 2 - call void @fasta_repeat_fasta(ptr %lo, i64 %hi, i32 %mul) + call void @fasta.repeat_fasta(ptr %lo, i64 %hi, i32 %mul) %6 = call i32 (ptr, ...) @printf(ptr @.str.15) - %lo1 = load ptr, ptr @fasta_iub, align 8 - %hi2 = load i64, ptr getelementptr inbounds (%"char[]", ptr @fasta_iub, i32 0, i32 1), align 8 - %lo3 = load ptr, ptr @fasta_iub_p, align 8 - %hi4 = load i64, ptr getelementptr inbounds (%"double[]", ptr @fasta_iub_p, i32 0, i32 1), align 8 + %lo1 = load ptr, ptr @fasta.iub, align 8 + %hi2 = load i64, ptr getelementptr inbounds (%"char[]", ptr @fasta.iub, i32 0, i32 1), align 8 + %lo3 = load ptr, ptr @fasta.iub_p, align 8 + %hi4 = load i64, ptr getelementptr inbounds (%"double[]", ptr @fasta.iub_p, i32 0, i32 1), align 8 %7 = load i32, ptr %n, align 4 %mul5 = mul i32 %7, 3 - call void @fasta_random_fasta(ptr %lo1, i64 %hi2, ptr %lo3, i64 %hi4, i32 %mul5) + call void @fasta.random_fasta(ptr %lo1, i64 %hi2, ptr %lo3, i64 %hi4, i32 %mul5) %8 = call i32 (ptr, ...) @printf(ptr @.str.16) - %lo6 = load ptr, ptr @fasta_homosapiens, align 8 - %hi7 = load i64, ptr getelementptr inbounds (%"char[]", ptr @fasta_homosapiens, i32 0, i32 1), align 8 - %lo8 = load ptr, ptr @fasta_homosapiens_p, align 8 - %hi9 = load i64, ptr getelementptr inbounds (%"double[]", ptr @fasta_homosapiens_p, i32 0, i32 1), align 8 + %lo6 = load ptr, ptr @fasta.homosapiens, align 8 + %hi7 = load i64, ptr getelementptr inbounds (%"char[]", ptr @fasta.homosapiens, i32 0, i32 1), align 8 + %lo8 = load ptr, ptr @fasta.homosapiens_p, align 8 + %hi9 = load i64, ptr getelementptr inbounds (%"double[]", ptr @fasta.homosapiens_p, i32 0, i32 1), align 8 %9 = load i32, ptr %n, align 4 %mul10 = mul i32 %9, 5 - call void @fasta_random_fasta(ptr %lo6, i64 %hi7, ptr %lo8, i64 %hi9, i32 %mul10) + call void @fasta.random_fasta(ptr %lo6, i64 %hi7, ptr %lo8, i64 %hi9, i32 %mul10) ret i32 0 } \ No newline at end of file diff --git a/test/test_suite/initializer_lists/general_tests.c3t b/test/test_suite/initializer_lists/general_tests.c3t index 0789d91ef..c329b920b 100644 --- a/test/test_suite/initializer_lists/general_tests.c3t +++ b/test/test_suite/initializer_lists/general_tests.c3t @@ -37,14 +37,14 @@ fn int test() %"int[]" = type { ptr, i64 } %"Bar[]" = type { ptr, i64 } -@"ct$general_tests_Baz" = linkonce constant %.introspect { i8 11, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 -@"ct$general_tests_Bar" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 +@"ct$general_tests.Baz" = linkonce constant %.introspect { i8 11, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 +@"ct$general_tests.Bar" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 @.__const = private unnamed_addr constant { i32, [4 x i8] } { i32 1, [4 x i8] undef }, align 8 @"test$foo1" = internal unnamed_addr global i32 22, align 4 @.str = private unnamed_addr constant [7 x i8] c"Hello!\00", align 1 ; Function Attrs: nounwind -define i32 @general_tests_test() #0 { +define i32 @general_tests.test() #0 { entry: %ffe = alloca %Baz, align 8 %azz = alloca [1 x i32], align 4 diff --git a/test/test_suite/initializer_lists/ranges_to_dynamic.c3t b/test/test_suite/initializer_lists/ranges_to_dynamic.c3t index e5a62f0af..8459bdc80 100644 --- a/test/test_suite/initializer_lists/ranges_to_dynamic.c3t +++ b/test/test_suite/initializer_lists/ranges_to_dynamic.c3t @@ -19,7 +19,7 @@ fn void main() /* #expect: test.ll -define void @test_test(i32 %0) #0 { +define void @test.test(i32 %0) #0 { entry: %y = alloca [10 x i32], align 16 %.anon = alloca i64, align 8 diff --git a/test/test_suite/initializer_lists/statics.c3t b/test/test_suite/initializer_lists/statics.c3t index 899956ca0..73dbd49f7 100644 --- a/test/test_suite/initializer_lists/statics.c3t +++ b/test/test_suite/initializer_lists/statics.c3t @@ -35,13 +35,13 @@ fn int main() %Bar = type { i32, i32 } %"Bar[]" = type { ptr, i64 } -@"ct$statics_Baz" = linkonce constant %.introspect { i8 11, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 -@"ct$statics_Bar" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 +@"ct$statics.Baz" = linkonce constant %.introspect { i8 11, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 +@"ct$statics.Bar" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 @.taddr = private global [1 x %Bar] [%Bar { i32 1, i32 2 }], align 8 @"test$c" = internal unnamed_addr global %"Bar[]" { ptr @.taddr, i64 1 }, align 8 @.str = private unnamed_addr constant [7 x i8] c"%d %d\0A\00", align 1 -define void @statics_test() #0 { +define void @statics.test() #0 { entry: %b = alloca %"Bar[]", align 8 %literal = alloca [1 x %Bar], align 4 @@ -81,9 +81,9 @@ entry: define i32 @main() #0 { entry: - call void @statics_test() - call void @statics_test() - call void @statics_test() + call void @statics.test() + call void @statics.test() + call void @statics.test() ret i32 1 } diff --git a/test/test_suite/initializer_lists/subarrays.c3t b/test/test_suite/initializer_lists/subarrays.c3t index f183ee0db..4be64b041 100644 --- a/test/test_suite/initializer_lists/subarrays.c3t +++ b/test/test_suite/initializer_lists/subarrays.c3t @@ -49,14 +49,14 @@ fn int main() %"Bar[]" = type { ptr, i64 } %"int[]" = type { ptr, i64 } %Baz = type { double } -@"ct$subarrays_Baz" = linkonce constant %.introspect { i8 11, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 -@"ct$subarrays_Bar" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 +@"ct$subarrays.Baz" = linkonce constant %.introspect { i8 11, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 +@"ct$subarrays.Bar" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 @.taddr = private global [2 x %Bar] [%Bar { i32 3, i32 4 }, %Bar { i32 8, i32 9 }], align 8 -@subarrays_arrbar = local_unnamed_addr global %"Bar[]" { ptr @.taddr, i64 2 }, align 8 +@subarrays.arrbar = local_unnamed_addr global %"Bar[]" { ptr @.taddr, i64 2 }, align 8 @.taddr.3 = private global [2 x i32] [i32 1, i32 2], align 4 -@subarrays_xd = local_unnamed_addr global %"int[]" { ptr @.taddr.3, i64 2 }, align 8 +@subarrays.xd = local_unnamed_addr global %"int[]" { ptr @.taddr.3, i64 2 }, align 8 @.taddr.4 = private global [2 x i32] [i32 3, i32 4], align 4 -@subarrays_fofeo = local_unnamed_addr global ptr @.taddr.4, align 8 +@subarrays.fofeo = local_unnamed_addr global ptr @.taddr.4, align 8 @.str = private unnamed_addr constant [4 x i8] c"%d\0A\00", align 1 @.str.5 = private unnamed_addr constant [7 x i8] c"Start:\00", align 1 @.str.6 = private unnamed_addr constant [26 x i8] c"X len: %d mid element %d\0A\00", align 1 @@ -87,10 +87,10 @@ entry: %sub = alloca %"int[]", align 8 %foo = alloca %"Bar[]", align 8 %baz = alloca [3 x %Baz], align 16 - %0 = load ptr, ptr @subarrays_arrbar, align 8 + %0 = load ptr, ptr @subarrays.arrbar, align 8 %ptroffset = getelementptr inbounds %Bar, ptr %0, i64 1 call void @llvm.memcpy.p0.p0.i32(ptr align 4 %w, ptr align 4 %ptroffset, i32 8, i1 false) - %1 = load ptr, ptr @subarrays_arrbar, align 8 + %1 = load ptr, ptr @subarrays.arrbar, align 8 %ptroffset1 = getelementptr inbounds %Bar, ptr %1, i64 1 %2 = getelementptr inbounds %Bar, ptr %ptroffset1, i32 0, i32 0 %3 = load i32, ptr %2, align 4 @@ -112,10 +112,10 @@ entry: store i32 567, ptr %12, align 4 store ptr %literal2, ptr %y, align 8 store ptr @.str.5, ptr %x3, align 8 - %13 = call ptr @std_io_stdout() + %13 = call ptr @std_io.stdout() store ptr %13, ptr %result, align 8 %14 = load ptr, ptr %x3, align 8 - %15 = call i64 @std_io_File_printn(ptr %retparam, ptr %result, ptr %14, i64 6) + %15 = call i64 @std_io.File_printn(ptr %retparam, ptr %result, ptr %14, i64 6) %16 = getelementptr inbounds %"int[]", ptr %x, i32 0, i32 1 %17 = load i64, ptr %16, align 8 %uisitrunc = trunc i64 %17 to i32 @@ -128,7 +128,7 @@ entry: %ptroffset5 = getelementptr inbounds i32, ptr %22, i64 1 %23 = load i32, ptr %ptroffset5, align 4 %24 = call i32 (ptr, ...) @printf(ptr @.str.7, i32 %23) - %25 = load ptr, ptr @subarrays_fofeo, align 8 + %25 = load ptr, ptr @subarrays.fofeo, align 8 %ptroffset6 = getelementptr inbounds i32, ptr %25, i64 1 %26 = load i32, ptr %ptroffset6, align 4 %27 = call i32 (ptr, ...) @printf(ptr @.str.8, i32 %26) @@ -154,10 +154,10 @@ entry: if.then: ; preds = %entry store ptr @.str.9, ptr %x9, align 8 - %38 = call ptr @std_io_stdout() + %38 = call ptr @std_io.stdout() store ptr %38, ptr %result11, align 8 %39 = load ptr, ptr %x9, align 8 - %40 = call i64 @std_io_File_printn(ptr %retparam10, ptr %result11, ptr %39, i64 2) + %40 = call i64 @std_io.File_printn(ptr %retparam10, ptr %result11, ptr %39, i64 2) br label %if.exit if.exit: ; preds = %if.then, %entry diff --git a/test/test_suite/initializer_lists/zero_init.c3t b/test/test_suite/initializer_lists/zero_init.c3t index 7c6fbf1bc..eeeb31d0a 100644 --- a/test/test_suite/initializer_lists/zero_init.c3t +++ b/test/test_suite/initializer_lists/zero_init.c3t @@ -34,7 +34,7 @@ fn int test() %Bar = type { i32, i32 } %Baz = type { double } -define i32 @zero_init_test() #0 { +define i32 @zero_init.test() #0 { entry: %m = alloca %Mega, align 4 %azz = alloca [1 x i32], align 4 diff --git a/test/test_suite/lambda/lambda_in_macro.c3t b/test/test_suite/lambda/lambda_in_macro.c3t index 4c5b4b681..8e057ab3b 100644 --- a/test/test_suite/lambda/lambda_in_macro.c3t +++ b/test/test_suite/lambda/lambda_in_macro.c3t @@ -29,17 +29,17 @@ fn void main() /* #expect: test.ll - store ptr @"test_test$lambda1", ptr %z, align 8 + store ptr @"test.test$lambda1", ptr %z, align 8 %1 = call i32 %0(i32 3) - store ptr @"test_test$lambda2", ptr %z3, align 8 + store ptr @"test.test$lambda2", ptr %z3, align 8 %7 = call double %6(double 3.300000e+00) - store ptr @"test_test$lambda2", ptr %z7, align 8 + store ptr @"test.test$lambda2", ptr %z7, align 8 %13 = call double %12(double 3.300000e+00) - %18 = call i32 @"test_test2$lambda3"(i32 3) - %23 = call i32 @"test_test2$lambda3"(i32 3) - %28 = call double @"test_test2$lambda4"(double 3.300000e+00) + %18 = call i32 @"test.test2$lambda3"(i32 3) + %23 = call i32 @"test.test2$lambda3"(i32 3) + %28 = call double @"test.test2$lambda4"(double 3.300000e+00) -define internal double @"test_test2$lambda4"(double %0) #0 { -define internal i32 @"test_test2$lambda3"(i32 %0) #0 { -define internal double @"test_test$lambda2"(double %0) #0 { -define internal i32 @"test_test$lambda1"(i32 %0) #0 { +define internal double @"test.test2$lambda4"(double %0) #0 { +define internal i32 @"test.test2$lambda3"(i32 %0) #0 { +define internal double @"test.test$lambda2"(double %0) #0 { +define internal i32 @"test.test$lambda1"(i32 %0) #0 { diff --git a/test/test_suite/lambda/nested_lambda_def.c3t b/test/test_suite/lambda/nested_lambda_def.c3t index 28a2236f9..8f05043df 100644 --- a/test/test_suite/lambda/nested_lambda_def.c3t +++ b/test/test_suite/lambda/nested_lambda_def.c3t @@ -46,36 +46,36 @@ macro Callback get_callback2() /* #expect: abc.ll - store ptr @"bar_get_callback$lambda1", ptr %F, align 8 - %0 = call i32 @abc_xy(ptr @"bar_get_callback$lambda1") - %1 = call i32 @abc_xy(ptr @"bar_get_callback$lambda1") + store ptr @"bar.get_callback$lambda1", ptr %F, align 8 + %0 = call i32 @abc.xy(ptr @"bar.get_callback$lambda1") + %1 = call i32 @abc.xy(ptr @"bar.get_callback$lambda1") -declare i32 @"bar_get_callback$lambda1"() +declare i32 @"bar.get_callback$lambda1"() // #expect: foo.ll -define i32 @"foo_get_callback$lambda1"() #0 { - %0 = call i32 @"bar_get_callback2$lambda2"() +define i32 @"foo.get_callback$lambda1"() #0 { + %0 = call i32 @"bar.get_callback2$lambda2"() -define i32 @"foo_get_callback2$lambda2"() #0 { - %1 = load i32, ptr @foo_xz, align 4 +define i32 @"foo.get_callback2$lambda2"() #0 { + %1 = load i32, ptr @foo.xz, align 4 -declare i32 @"bar_get_callback2$lambda2"() +declare i32 @"bar.get_callback2$lambda2"() // #expect: bar.ll -define i32 @"bar_get_callback$lambda1"() #0 { +define i32 @"bar.get_callback$lambda1"() #0 { entry: - %0 = call i32 @"foo_get_callback$lambda1"() + %0 = call i32 @"foo.get_callback$lambda1"() ret i32 %0 } -define i32 @"bar_get_callback2$lambda2"() #0 { +define i32 @"bar.get_callback2$lambda2"() #0 { entry: - %0 = call i32 @"foo_get_callback2$lambda2"() + %0 = call i32 @"foo.get_callback2$lambda2"() ret i32 %0 } -declare i32 @"foo_get_callback$lambda1"() -declare i32 @"foo_get_callback2$lambda2"() +declare i32 @"foo.get_callback$lambda1"() +declare i32 @"foo.get_callback2$lambda2"() diff --git a/test/test_suite/lambda/simple_lambda.c3t b/test/test_suite/lambda/simple_lambda.c3t index 431701803..0c8c4d21e 100644 --- a/test/test_suite/lambda/simple_lambda.c3t +++ b/test/test_suite/lambda/simple_lambda.c3t @@ -17,13 +17,13 @@ fn void main() /* #expect: simple_lambda.ll -define void @simple_lambda_main() #0 { +define void @simple_lambda.main() #0 { entry: %F = alloca ptr, align 8 %z = alloca i32, align 4 - store ptr @"simple_lambda_main$lambda1", ptr %F, align 8 - %0 = call i32 @simple_lambda_xy(ptr @"simple_lambda_main$lambda1") - %5 = call i32 @simple_lambda_xy(ptr @"simple_lambda_main$lambda2") + store ptr @"simple_lambda.main$lambda1", ptr %F, align 8 + %0 = call i32 @simple_lambda.xy(ptr @"simple_lambda.main$lambda1") + %5 = call i32 @simple_lambda.xy(ptr @"simple_lambda.main$lambda2") -define internal i32 @"simple_lambda_main$lambda2"() #0 { -define internal i32 @"simple_lambda_main$lambda1"() #0 { \ No newline at end of file +define internal i32 @"simple_lambda.main$lambda2"() #0 { +define internal i32 @"simple_lambda.main$lambda1"() #0 { \ No newline at end of file diff --git a/test/test_suite/literals/bin_literal.c3t b/test/test_suite/literals/bin_literal.c3t index 80f3aaed4..bafd6b525 100644 --- a/test/test_suite/literals/bin_literal.c3t +++ b/test/test_suite/literals/bin_literal.c3t @@ -15,7 +15,7 @@ fn void main() /* #expect: test.ll -define void @test_main() #0 { +define void @test.main() #0 { entry: %a = alloca i32, align 4 %b = alloca i32, align 4 @@ -50,7 +50,7 @@ entry: %10 = insertvalue %variant %9, i64 ptrtoint (ptr @"ct$int" to i64), 1 %11 = getelementptr inbounds [2 x %variant], ptr %varargslots, i64 0, i64 1 store %variant %10, ptr %11, align 16 - %12 = call i64 @std_io_printfn(ptr %retparam, ptr @.str, i64 5, ptr %varargslots, i64 2) + %12 = call i64 @std_io.printfn(ptr %retparam, ptr @.str, i64 5, ptr %varargslots, i64 2) store i8 -35, ptr %z, align 1 %13 = insertvalue %variant undef, ptr %z, 0 %14 = insertvalue %variant %13, i64 ptrtoint (ptr @"ct$char" to i64), 1 @@ -80,6 +80,6 @@ entry: %30 = insertvalue %variant %29, i64 ptrtoint (ptr @"ct$char" to i64), 1 %31 = getelementptr inbounds [3 x %variant], ptr %varargslots2, i64 0, i64 2 store %variant %30, ptr %31, align 16 - %32 = call i64 @std_io_printfn(ptr %retparam1, ptr @.str.1, i64 8, ptr %varargslots2, i64 3) + %32 = call i64 @std_io.printfn(ptr %retparam1, ptr @.str.1, i64 8, ptr %varargslots2, i64 3) ret void } diff --git a/test/test_suite/literals/literal_general.c3t b/test/test_suite/literals/literal_general.c3t index d623f4585..377c6096e 100644 --- a/test/test_suite/literals/literal_general.c3t +++ b/test/test_suite/literals/literal_general.c3t @@ -12,11 +12,11 @@ uint foo = '謝'; /* #expect: foo.ll -@foo_aa = local_unnamed_addr global i32 228, align 4 -@foo_x = local_unnamed_addr global i32 1094861636, align 4 -@foo_y = local_unnamed_addr global i32 1214606447, align 4 -@foo_z = local_unnamed_addr global i16 12594, align 2 -@foo_d = local_unnamed_addr global i32 49, align 4 -@foo_b = local_unnamed_addr global i8 64, align 1 -@foo_abc = local_unnamed_addr global i32 322052779, align 4 -@foo_foo = local_unnamed_addr global i32 35613, align 4 +@foo.aa = local_unnamed_addr global i32 228, align 4 +@foo.x = local_unnamed_addr global i32 1094861636, align 4 +@foo.y = local_unnamed_addr global i32 1214606447, align 4 +@foo.z = local_unnamed_addr global i16 12594, align 2 +@foo.d = local_unnamed_addr global i32 49, align 4 +@foo.b = local_unnamed_addr global i8 64, align 1 +@foo.abc = local_unnamed_addr global i32 322052779, align 4 +@foo.foo = local_unnamed_addr global i32 35613, align 4 diff --git a/test/test_suite/macro_methods/macro_method_different_args.c3t b/test/test_suite/macro_methods/macro_method_different_args.c3t index 08c2a6a7e..330eea7a1 100644 --- a/test/test_suite/macro_methods/macro_method_different_args.c3t +++ b/test/test_suite/macro_methods/macro_method_different_args.c3t @@ -24,7 +24,7 @@ fn void main() /* #expect: foo.ll -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %a = alloca %Foo, align 4 %this = alloca ptr, align 8 diff --git a/test/test_suite/macros/macro_body_defer.c3t b/test/test_suite/macros/macro_body_defer.c3t index 80a1d19a5..8fb9b6614 100644 --- a/test/test_suite/macros/macro_body_defer.c3t +++ b/test/test_suite/macros/macro_body_defer.c3t @@ -49,14 +49,14 @@ fn void! main() /* #expect: foo.ll -define i64 @foo_foo(ptr %0) #0 { +define i64 @foo.foo(ptr %0) #0 { entry: %reterr = alloca i64, align 8 store i32 1, ptr %0, align 4 ret i64 0 } -define i64 @foo_main() #0 { +define i64 @foo.main() #0 { entry: %i = alloca i32, align 4 %i1 = alloca i32, align 4 @@ -110,7 +110,7 @@ entry: store i32 %0, ptr %.anon, align 4 store ptr %1, ptr %.anon1, align 8 store i64 0, ptr %error_var, align 8 - %2 = call i64 @foo_main() + %2 = call i64 @foo.main() %not_err = icmp eq i64 %2, 0 %3 = call i1 @llvm.expect.i1(i1 %not_err, i1 true) br i1 %3, label %after_check, label %assign_optional diff --git a/test/test_suite/macros/macro_common.c3t b/test/test_suite/macros/macro_common.c3t index e3cbf3ff6..925b08013 100644 --- a/test/test_suite/macros/macro_common.c3t +++ b/test/test_suite/macros/macro_common.c3t @@ -14,7 +14,7 @@ fn void test2() /* #expect: test.ll -define void @test_test2() #0 { +define void @test.test2() #0 { entry: %x = alloca i32, align 4 %blockret = alloca double, align 8 diff --git a/test/test_suite/macros/macro_defer_exit.c3t b/test/test_suite/macros/macro_defer_exit.c3t index dac68826c..207c9ecf8 100644 --- a/test/test_suite/macros/macro_defer_exit.c3t +++ b/test/test_suite/macros/macro_defer_exit.c3t @@ -20,7 +20,7 @@ fn void main() /* #expect: foo.ll -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %x = alloca i32, align 4 %blockret = alloca i32, align 4 diff --git a/test/test_suite/macros/macro_defer_scope.c3t b/test/test_suite/macros/macro_defer_scope.c3t index 3e8b4804a..0fb766794 100644 --- a/test/test_suite/macros/macro_defer_scope.c3t +++ b/test/test_suite/macros/macro_defer_scope.c3t @@ -18,7 +18,7 @@ fn void main() /* #expect: foo.ll -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %x = alloca i32, align 4 %blockret = alloca i32, align 4 diff --git a/test/test_suite/macros/macro_defer_with_body.c3t b/test/test_suite/macros/macro_defer_with_body.c3t index fc1932c92..17059c5c0 100644 --- a/test/test_suite/macros/macro_defer_with_body.c3t +++ b/test/test_suite/macros/macro_defer_with_body.c3t @@ -21,7 +21,7 @@ fn void main() /* #expect: foo.ll -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %x = alloca i32, align 4 %a = alloca i32, align 4 diff --git a/test/test_suite/macros/macro_failable_return_rethrow.c3t b/test/test_suite/macros/macro_failable_return_rethrow.c3t index 07285b1b4..1e303fd35 100644 --- a/test/test_suite/macros/macro_failable_return_rethrow.c3t +++ b/test/test_suite/macros/macro_failable_return_rethrow.c3t @@ -16,13 +16,13 @@ fn void main() /* #expect: test.ll -define void @test_main() #0 { +define void @test.main() #0 { entry: %error_var = alloca i64, align 8 %blockret = alloca i32, align 4 %error_var1 = alloca i64, align 8 %retparam = alloca i32, align 4 - %0 = call i64 @test_xy(ptr %retparam) + %0 = call i64 @test.xy(ptr %retparam) %not_err = icmp eq i64 %0, 0 %1 = call i1 @llvm.expect.i1(i1 %not_err, i1 true) br i1 %1, label %after_check, label %assign_optional diff --git a/test/test_suite/macros/macro_import_res_private.c3t b/test/test_suite/macros/macro_import_res_private.c3t index 410d28e5d..2fcc69cb3 100644 --- a/test/test_suite/macros/macro_import_res_private.c3t +++ b/test/test_suite/macros/macro_import_res_private.c3t @@ -19,8 +19,8 @@ fn void test() /* #expect: baz.ll -define void @baz_test() #0 { +define void @baz.test() #0 { entry: - call void @foo_foo1() + call void @foo.foo1() ret void } \ No newline at end of file diff --git a/test/test_suite/macros/macro_nested_labels.c3t b/test/test_suite/macros/macro_nested_labels.c3t index 42133c4e7..28989b76d 100644 --- a/test/test_suite/macros/macro_nested_labels.c3t +++ b/test/test_suite/macros/macro_nested_labels.c3t @@ -28,7 +28,7 @@ fn void main() /* #expect: test.ll -define void @test_main() #0 { +define void @test.main() #0 { entry: %ab = alloca i32, align 4 %x = alloca i32, align 4 diff --git a/test/test_suite/macros/macro_typed_varargs.c3t b/test/test_suite/macros/macro_typed_varargs.c3t index 443b7f898..ad565a9a5 100644 --- a/test/test_suite/macros/macro_typed_varargs.c3t +++ b/test/test_suite/macros/macro_typed_varargs.c3t @@ -28,7 +28,7 @@ fn void main() /* #expect: test.ll -define void @test_main() #0 { +define void @test.main() #0 { entry: %x = alloca %"int[]", align 8 %literal = alloca [4 x i32], align 16 @@ -80,7 +80,7 @@ loop.body: ; preds = %loop.cond %15 = insertvalue %variant %14, i64 ptrtoint (ptr @"ct$int" to i64), 1 %16 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %15, ptr %16, align 16 - %17 = call i64 @std_io_printfn(ptr %retparam, ptr @.str, i64 2, ptr %varargslots, i64 1) + %17 = call i64 @std_io.printfn(ptr %retparam, ptr @.str, i64 2, ptr %varargslots, i64 1) %18 = load i64, ptr %.anon1, align 8 %add = add i64 %18, 1 store i64 %add, ptr %.anon1, align 8 @@ -131,7 +131,7 @@ loop.body11: ; preds = %loop.cond9 %43 = insertvalue %variant %42, i64 ptrtoint (ptr @"ct$int" to i64), 1 %44 = getelementptr inbounds [1 x %variant], ptr %varargslots15, i64 0, i64 0 store %variant %43, ptr %44, align 16 - %45 = call i64 @std_io_printfn(ptr %retparam14, ptr @.str.1, i64 2, ptr %varargslots15, i64 1) + %45 = call i64 @std_io.printfn(ptr %retparam14, ptr @.str.1, i64 2, ptr %varargslots15, i64 1) %46 = load i64, ptr %.anon8, align 8 %add16 = add i64 %46, 1 store i64 %add16, ptr %.anon8, align 8 diff --git a/test/test_suite/macros/macro_untyped_varargs_2.c3t b/test/test_suite/macros/macro_untyped_varargs_2.c3t index 67d8e7668..8d8060ba8 100644 --- a/test/test_suite/macros/macro_untyped_varargs_2.c3t +++ b/test/test_suite/macros/macro_untyped_varargs_2.c3t @@ -60,7 +60,7 @@ fn void main() /* #expect: test.ll -define i32 @test_ping(i32 %0) #0 { +define i32 @test.ping(i32 %0) #0 { entry: %retparam = alloca i64, align 8 %varargslots = alloca [1 x %variant], align 16 @@ -70,11 +70,11 @@ entry: %2 = insertvalue %variant %1, i64 ptrtoint (ptr @"ct$int" to i64), 1 %3 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %2, ptr %3, align 16 - %4 = call i64 @std_io_printfn(ptr %retparam, ptr @.str, i64 8, ptr %varargslots, i64 1) + %4 = call i64 @std_io.printfn(ptr %retparam, ptr @.str, i64 8, ptr %varargslots, i64 1) ret i32 %0 } -define void @test_main() #0 { +define void @test.main() #0 { entry: %.anon = alloca i32, align 4 %.anon1 = alloca i32, align 4 @@ -109,62 +109,62 @@ entry: %a23 = alloca i32, align 4 %retparam24 = alloca i64, align 8 %varargslots25 = alloca [2 x %variant], align 16 - %0 = call i32 @test_ping(i32 -1) + %0 = call i32 @test.ping(i32 -1) store i32 %0, ptr %.anon, align 4 - %1 = call i32 @test_ping(i32 1) + %1 = call i32 @test.ping(i32 1) store i32 %1, ptr %.anon1, align 4 - %2 = call i32 @test_ping(i32 3141) + %2 = call i32 @test.ping(i32 3141) store i32 %2, ptr %.anon2, align 4 - %3 = call i32 @test_ping(i32 1000) + %3 = call i32 @test.ping(i32 1000) store i32 %3, ptr %.anon3, align 4 %4 = load i32, ptr %.anon, align 4 %5 = load i32, ptr %.anon, align 4 %add = add i32 %4, %5 store i32 %add, ptr %i, align 4 - %6 = call i32 @test_ping(i32 3141) - %7 = call i32 @test_ping(i32 3141) + %6 = call i32 @test.ping(i32 3141) + %7 = call i32 @test.ping(i32 3141) %add4 = add i32 %6, %7 store i32 %add4, ptr %j, align 4 %8 = insertvalue %variant undef, ptr %.anon1, 0 %9 = insertvalue %variant %8, i64 ptrtoint (ptr @"ct$int" to i64), 1 %10 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %9, ptr %10, align 16 - %11 = call i64 @std_io_printfn(ptr %retparam, ptr @.str.1, i64 2, ptr %varargslots, i64 1) + %11 = call i64 @std_io.printfn(ptr %retparam, ptr @.str.1, i64 2, ptr %varargslots, i64 1) %12 = insertvalue %variant undef, ptr %.anon, 0 %13 = insertvalue %variant %12, i64 ptrtoint (ptr @"ct$int" to i64), 1 %14 = getelementptr inbounds [1 x %variant], ptr %varargslots6, i64 0, i64 0 store %variant %13, ptr %14, align 16 - %15 = call i64 @std_io_printfn(ptr %retparam5, ptr @.str.2, i64 2, ptr %varargslots6, i64 1) + %15 = call i64 @std_io.printfn(ptr %retparam5, ptr @.str.2, i64 2, ptr %varargslots6, i64 1) %16 = insertvalue %variant undef, ptr %.anon2, 0 %17 = insertvalue %variant %16, i64 ptrtoint (ptr @"ct$int" to i64), 1 %18 = getelementptr inbounds [1 x %variant], ptr %varargslots8, i64 0, i64 0 store %variant %17, ptr %18, align 16 - %19 = call i64 @std_io_printfn(ptr %retparam7, ptr @.str.3, i64 2, ptr %varargslots8, i64 1) + %19 = call i64 @std_io.printfn(ptr %retparam7, ptr @.str.3, i64 2, ptr %varargslots8, i64 1) %20 = insertvalue %variant undef, ptr %.anon3, 0 %21 = insertvalue %variant %20, i64 ptrtoint (ptr @"ct$int" to i64), 1 %22 = getelementptr inbounds [1 x %variant], ptr %varargslots10, i64 0, i64 0 store %variant %21, ptr %22, align 16 - %23 = call i64 @std_io_printfn(ptr %retparam9, ptr @.str.4, i64 2, ptr %varargslots10, i64 1) + %23 = call i64 @std_io.printfn(ptr %retparam9, ptr @.str.4, i64 2, ptr %varargslots10, i64 1) store i32 0, ptr %x, align 4 store ptr @.str.6, ptr %taddr, align 8 %24 = insertvalue %variant undef, ptr %taddr, 0 %25 = insertvalue %variant %24, i64 ptrtoint (ptr @"ct$p$a3$char" to i64), 1 %26 = getelementptr inbounds [1 x %variant], ptr %varargslots12, i64 0, i64 0 store %variant %25, ptr %26, align 16 - %27 = call i64 @std_io_printfn(ptr %retparam11, ptr @.str.5, i64 2, ptr %varargslots12, i64 1) + %27 = call i64 @std_io.printfn(ptr %retparam11, ptr @.str.5, i64 2, ptr %varargslots12, i64 1) store double 0.000000e+00, ptr %x13, align 8 store ptr @.str.8, ptr %taddr16, align 8 %28 = insertvalue %variant undef, ptr %taddr16, 0 %29 = insertvalue %variant %28, i64 ptrtoint (ptr @"ct$p$a6$char" to i64), 1 %30 = getelementptr inbounds [1 x %variant], ptr %varargslots15, i64 0, i64 0 store %variant %29, ptr %30, align 16 - %31 = call i64 @std_io_printfn(ptr %retparam14, ptr @.str.7, i64 2, ptr %varargslots15, i64 1) + %31 = call i64 @std_io.printfn(ptr %retparam14, ptr @.str.7, i64 2, ptr %varargslots15, i64 1) store i32 105, ptr %taddr19, align 4 %32 = insertvalue %variant undef, ptr %taddr19, 0 %33 = insertvalue %variant %32, i64 ptrtoint (ptr @"ct$int" to i64), 1 %34 = getelementptr inbounds [1 x %variant], ptr %varargslots18, i64 0, i64 0 store %variant %33, ptr %34, align 16 - %35 = call i64 @std_io_printfn(ptr %retparam17, ptr @.str.9, i64 2, ptr %varargslots18, i64 1) + %35 = call i64 @std_io.printfn(ptr %retparam17, ptr @.str.9, i64 2, ptr %varargslots18, i64 1) store i32 123, ptr %x20, align 4 store i32 33, ptr %y, align 4 %36 = load i32, ptr %x20, align 4 @@ -181,7 +181,7 @@ entry: %43 = insertvalue %variant %42, i64 ptrtoint (ptr @"ct$int" to i64), 1 %44 = getelementptr inbounds [2 x %variant], ptr %varargslots22, i64 0, i64 1 store %variant %43, ptr %44, align 16 - %45 = call i64 @std_io_printfn(ptr %retparam21, ptr @.str.10, i64 6, ptr %varargslots22, i64 2) + %45 = call i64 @std_io.printfn(ptr %retparam21, ptr @.str.10, i64 6, ptr %varargslots22, i64 2) %46 = load i32, ptr %x20, align 4 store i32 %46, ptr %a23, align 4 %47 = load i32, ptr %y, align 4 @@ -196,6 +196,6 @@ entry: %53 = insertvalue %variant %52, i64 ptrtoint (ptr @"ct$int" to i64), 1 %54 = getelementptr inbounds [2 x %variant], ptr %varargslots25, i64 0, i64 1 store %variant %53, ptr %54, align 16 - %55 = call i64 @std_io_printfn(ptr %retparam24, ptr @.str.11, i64 6, ptr %varargslots25, i64 2) + %55 = call i64 @std_io.printfn(ptr %retparam24, ptr @.str.11, i64 6, ptr %varargslots25, i64 2) ret void } \ No newline at end of file diff --git a/test/test_suite/macros/macro_vasplat.c3t b/test/test_suite/macros/macro_vasplat.c3t index cef800109..20edc755c 100644 --- a/test/test_suite/macros/macro_vasplat.c3t +++ b/test/test_suite/macros/macro_vasplat.c3t @@ -62,7 +62,7 @@ fn void main() /* #expect: test.ll -define void @test_main() #0 { +define void @test.main() #0 { entry: %a = alloca [3 x i32], align 4 %.anon = alloca i64, align 8 @@ -160,7 +160,7 @@ loop.body: ; preds = %loop.cond %9 = insertvalue %variant %8, i64 ptrtoint (ptr @"ct$int" to i64), 1 %10 = getelementptr inbounds [2 x %variant], ptr %varargslots, i64 0, i64 1 store %variant %9, ptr %10, align 16 - %11 = call i64 @std_io_printfn(ptr %retparam, ptr @.str, i64 8, ptr %varargslots, i64 2) + %11 = call i64 @std_io.printfn(ptr %retparam, ptr @.str, i64 8, ptr %varargslots, i64 2) %12 = load i64, ptr %.anon, align 8 %add = add i64 %12, 1 store i64 %add, ptr %.anon, align 8 @@ -191,7 +191,7 @@ loop.body5: ; preds = %loop.cond3 %22 = insertvalue %variant %21, i64 ptrtoint (ptr @"ct$int" to i64), 1 %23 = getelementptr inbounds [2 x %variant], ptr %varargslots9, i64 0, i64 1 store %variant %22, ptr %23, align 16 - %24 = call i64 @std_io_printfn(ptr %retparam8, ptr @.str.2, i64 8, ptr %varargslots9, i64 2) + %24 = call i64 @std_io.printfn(ptr %retparam8, ptr @.str.2, i64 8, ptr %varargslots9, i64 2) %25 = load i64, ptr %.anon2, align 8 %add10 = add i64 %25, 1 store i64 %add10, ptr %.anon2, align 8 @@ -222,7 +222,7 @@ loop.body16: ; preds = %loop.cond14 %35 = insertvalue %variant %34, i64 ptrtoint (ptr @"ct$int" to i64), 1 %36 = getelementptr inbounds [2 x %variant], ptr %varargslots20, i64 0, i64 1 store %variant %35, ptr %36, align 16 - %37 = call i64 @std_io_printfn(ptr %retparam19, ptr @.str.4, i64 6, ptr %varargslots20, i64 2) + %37 = call i64 @std_io.printfn(ptr %retparam19, ptr @.str.4, i64 6, ptr %varargslots20, i64 2) %38 = load i64, ptr %.anon13, align 8 %add21 = add i64 %38, 1 store i64 %add21, ptr %.anon13, align 8 @@ -253,7 +253,7 @@ loop.body27: ; preds = %loop.cond25 %48 = insertvalue %variant %47, i64 ptrtoint (ptr @"ct$int" to i64), 1 %49 = getelementptr inbounds [2 x %variant], ptr %varargslots31, i64 0, i64 1 store %variant %48, ptr %49, align 16 - %50 = call i64 @std_io_printfn(ptr %retparam30, ptr @.str.6, i64 6, ptr %varargslots31, i64 2) + %50 = call i64 @std_io.printfn(ptr %retparam30, ptr @.str.6, i64 6, ptr %varargslots31, i64 2) %51 = load i64, ptr %.anon24, align 8 %add32 = add i64 %51, 1 store i64 %add32, ptr %.anon24, align 8 @@ -284,7 +284,7 @@ loop.body38: ; preds = %loop.cond36 %61 = insertvalue %variant %60, i64 ptrtoint (ptr @"ct$int" to i64), 1 %62 = getelementptr inbounds [2 x %variant], ptr %varargslots42, i64 0, i64 1 store %variant %61, ptr %62, align 16 - %63 = call i64 @std_io_printfn(ptr %retparam41, ptr @.str.8, i64 8, ptr %varargslots42, i64 2) + %63 = call i64 @std_io.printfn(ptr %retparam41, ptr @.str.8, i64 8, ptr %varargslots42, i64 2) %64 = load i64, ptr %.anon35, align 8 %add43 = add i64 %64, 1 store i64 %add43, ptr %.anon35, align 8 @@ -315,7 +315,7 @@ loop.body49: ; preds = %loop.cond47 %74 = insertvalue %variant %73, i64 ptrtoint (ptr @"ct$int" to i64), 1 %75 = getelementptr inbounds [2 x %variant], ptr %varargslots53, i64 0, i64 1 store %variant %74, ptr %75, align 16 - %76 = call i64 @std_io_printfn(ptr %retparam52, ptr @.str.10, i64 8, ptr %varargslots53, i64 2) + %76 = call i64 @std_io.printfn(ptr %retparam52, ptr @.str.10, i64 8, ptr %varargslots53, i64 2) %77 = load i64, ptr %.anon46, align 8 %add54 = add i64 %77, 1 store i64 %add54, ptr %.anon46, align 8 @@ -346,7 +346,7 @@ loop.body60: ; preds = %loop.cond58 %87 = insertvalue %variant %86, i64 ptrtoint (ptr @"ct$int" to i64), 1 %88 = getelementptr inbounds [2 x %variant], ptr %varargslots64, i64 0, i64 1 store %variant %87, ptr %88, align 16 - %89 = call i64 @std_io_printfn(ptr %retparam63, ptr @.str.12, i64 8, ptr %varargslots64, i64 2) + %89 = call i64 @std_io.printfn(ptr %retparam63, ptr @.str.12, i64 8, ptr %varargslots64, i64 2) %90 = load i64, ptr %.anon57, align 8 %add65 = add i64 %90, 1 store i64 %add65, ptr %.anon57, align 8 @@ -377,7 +377,7 @@ loop.body71: ; preds = %loop.cond69 %100 = insertvalue %variant %99, i64 ptrtoint (ptr @"ct$int" to i64), 1 %101 = getelementptr inbounds [2 x %variant], ptr %varargslots75, i64 0, i64 1 store %variant %100, ptr %101, align 16 - %102 = call i64 @std_io_printfn(ptr %retparam74, ptr @.str.14, i64 8, ptr %varargslots75, i64 2) + %102 = call i64 @std_io.printfn(ptr %retparam74, ptr @.str.14, i64 8, ptr %varargslots75, i64 2) %103 = load i64, ptr %.anon68, align 8 %add76 = add i64 %103, 1 store i64 %add76, ptr %.anon68, align 8 @@ -408,7 +408,7 @@ loop.body82: ; preds = %loop.cond80 %113 = insertvalue %variant %112, i64 ptrtoint (ptr @"ct$int" to i64), 1 %114 = getelementptr inbounds [2 x %variant], ptr %varargslots86, i64 0, i64 1 store %variant %113, ptr %114, align 16 - %115 = call i64 @std_io_printfn(ptr %retparam85, ptr @.str.16, i64 8, ptr %varargslots86, i64 2) + %115 = call i64 @std_io.printfn(ptr %retparam85, ptr @.str.16, i64 8, ptr %varargslots86, i64 2) %116 = load i64, ptr %.anon79, align 8 %add87 = add i64 %116, 1 store i64 %add87, ptr %.anon79, align 8 @@ -439,7 +439,7 @@ loop.body92: ; preds = %loop.cond90 %126 = insertvalue %variant %125, i64 ptrtoint (ptr @"ct$int" to i64), 1 %127 = getelementptr inbounds [2 x %variant], ptr %varargslots96, i64 0, i64 1 store %variant %126, ptr %127, align 16 - %128 = call i64 @std_io_printfn(ptr %retparam95, ptr @.str.18, i64 8, ptr %varargslots96, i64 2) + %128 = call i64 @std_io.printfn(ptr %retparam95, ptr @.str.18, i64 8, ptr %varargslots96, i64 2) %129 = load i64, ptr %.anon89, align 8 %add97 = add i64 %129, 1 store i64 %add97, ptr %.anon89, align 8 @@ -470,7 +470,7 @@ loop.body102: ; preds = %loop.cond100 %139 = insertvalue %variant %138, i64 ptrtoint (ptr @"ct$int" to i64), 1 %140 = getelementptr inbounds [2 x %variant], ptr %varargslots106, i64 0, i64 1 store %variant %139, ptr %140, align 16 - %141 = call i64 @std_io_printfn(ptr %retparam105, ptr @.str.20, i64 9, ptr %varargslots106, i64 2) + %141 = call i64 @std_io.printfn(ptr %retparam105, ptr @.str.20, i64 9, ptr %varargslots106, i64 2) %142 = load i64, ptr %.anon99, align 8 %add107 = add i64 %142, 1 store i64 %add107, ptr %.anon99, align 8 @@ -501,7 +501,7 @@ loop.body113: ; preds = %loop.cond111 %152 = insertvalue %variant %151, i64 ptrtoint (ptr @"ct$int" to i64), 1 %153 = getelementptr inbounds [2 x %variant], ptr %varargslots117, i64 0, i64 1 store %variant %152, ptr %153, align 16 - %154 = call i64 @std_io_printfn(ptr %retparam116, ptr @.str.22, i64 6, ptr %varargslots117, i64 2) + %154 = call i64 @std_io.printfn(ptr %retparam116, ptr @.str.22, i64 6, ptr %varargslots117, i64 2) %155 = load i64, ptr %.anon110, align 8 %add118 = add i64 %155, 1 store i64 %add118, ptr %.anon110, align 8 diff --git a/test/test_suite/macros/macro_with_body.c3t b/test/test_suite/macros/macro_with_body.c3t index f7b5ffde9..19ef40a9b 100644 --- a/test/test_suite/macros/macro_with_body.c3t +++ b/test/test_suite/macros/macro_with_body.c3t @@ -45,7 +45,7 @@ fn void main() /* #expect: withbody.ll -define i32 @withbody_Foo_mutate(ptr %0) #0 { +define i32 @withbody.Foo_mutate(ptr %0) #0 { entry: %1 = call i32 (ptr, ...) @printf(ptr @.str.2) %2 = getelementptr inbounds %Foo, ptr %0, i32 0, i32 0 @@ -56,7 +56,7 @@ entry: ret i32 %mul } -define void @withbody_main() #0 { +define void @withbody.main() #0 { entry: %f = alloca %Foo, align 4 %y = alloca i32, align 4 @@ -72,7 +72,7 @@ entry: %0 = getelementptr inbounds %Foo, ptr %foo, i32 0, i32 0 %1 = load i32, ptr %0, align 4 store i32 %1, ptr %y, align 4 - %2 = call i32 @withbody_Foo_mutate(ptr %foo) + %2 = call i32 @withbody.Foo_mutate(ptr %foo) store i32 %2, ptr %x, align 4 %3 = load i32, ptr %y, align 4 store i32 %3, ptr %dy, align 4 diff --git a/test/test_suite/macros/userland_bitcast.c3t b/test/test_suite/macros/userland_bitcast.c3t index 459d5967f..22a26b3c9 100644 --- a/test/test_suite/macros/userland_bitcast.c3t +++ b/test/test_suite/macros/userland_bitcast.c3t @@ -78,11 +78,11 @@ fn void main() %Foo = type { i16, i8, i8, i16, i16 } -@"ct$userland_bitcast_Foo" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 5, [0 x i64] zeroinitializer }, align 8 +@"ct$userland_bitcast.Foo" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 5, [0 x i64] zeroinitializer }, align 8 @.str = private unnamed_addr constant [16 x i8] c"%f => %d => %f\0A\00", align 1 @.str.1 = private unnamed_addr constant [18 x i8] c"%e => %llu => %e\0A\00", align 1 -define i64 @userland_bitcast_testFoo(i16 signext %0) #0 { +define i64 @userland_bitcast.testFoo(i16 signext %0) #0 { entry: %z = alloca %Foo, align 2 %expr = alloca %Foo, align 2 @@ -132,7 +132,7 @@ loop.exit: ; preds = %loop.cond ret i64 %14 } -define i32 @userland_bitcast_test(float %0) #0 { +define i32 @userland_bitcast.test(float %0) #0 { entry: %expr = alloca float, align 4 %x = alloca [4 x i8], align 1 @@ -169,7 +169,7 @@ loop.exit: ; preds = %loop.cond ret i32 %8 } -define void @userland_bitcast_main() #0 { +define void @userland_bitcast.main() #0 { entry: %f = alloca float, align 4 %i = alloca i32, align 4 diff --git a/test/test_suite/methods/enum_distinct_err_methods.c3t b/test/test_suite/methods/enum_distinct_err_methods.c3t index d4a97fc8f..239b4977d 100644 --- a/test/test_suite/methods/enum_distinct_err_methods.c3t +++ b/test/test_suite/methods/enum_distinct_err_methods.c3t @@ -43,18 +43,18 @@ fn int main() /* #expect: foo.ll -define void @foo_Foo_hello(ptr %0) #0 { +define void @foo.Foo_hello(ptr %0) #0 { entry: store ptr @.str, ptr %x, align 8 ret void } -define void @foo_Bar_hello(ptr %0) #0 { +define void @foo.Bar_hello(ptr %0) #0 { entry: store ptr @.str.1, ptr %x, align 8 } -define void @foo_MyEnum_hello(ptr %0) #0 { +define void @foo.MyEnum_hello(ptr %0) #0 { entry: store ptr @.str.2, ptr %x, align 8 } @@ -67,8 +67,8 @@ entry: store i64 0, ptr %f, align 8 store i32 0, ptr %b, align 4 store i32 0, ptr %a, align 4 - call void @foo_Foo_hello(ptr %f) - call void @foo_Bar_hello(ptr %b) - call void @foo_MyEnum_hello(ptr %a) + call void @foo.Foo_hello(ptr %f) + call void @foo.Bar_hello(ptr %b) + call void @foo.MyEnum_hello(ptr %a) ret i32 0 } \ No newline at end of file diff --git a/test/test_suite/methods/extension_method.c3t b/test/test_suite/methods/extension_method.c3t index 3f215c1fe..44841a046 100644 --- a/test/test_suite/methods/extension_method.c3t +++ b/test/test_suite/methods/extension_method.c3t @@ -33,8 +33,8 @@ define i32 @main() #0 { entry: %bar = alloca %Bar, align 4 store i32 0, ptr %bar, align 4 - call void @foo_Bar_test(ptr %bar) + call void @foo.Bar_test(ptr %bar) ret i32 0 } -declare void @foo_Bar_test(ptr) +declare void @foo.Bar_test(ptr) diff --git a/test/test_suite/methods/extension_method_in_other_modules.c3t b/test/test_suite/methods/extension_method_in_other_modules.c3t index d890ade5f..ec0c90ed5 100644 --- a/test/test_suite/methods/extension_method_in_other_modules.c3t +++ b/test/test_suite/methods/extension_method_in_other_modules.c3t @@ -20,23 +20,23 @@ fn void main() /* #expect: foob.ll -define void @foob_Foo_test(ptr %0) #0 { +define void @foob.Foo_test(ptr %0) #0 { entry: ret void } // #expect: baz.ll -define void @foob_Foo_test2(ptr %0, i32 %1) #0 { +define void @foob.Foo_test2(ptr %0, i32 %1) #0 { entry: ret void } -define void @baz_main() #0 { +define void @baz.main() #0 { entry: %f = alloca %Foo, align 4 store i32 0, ptr %f, align 4 - call void @foob_Foo_test(ptr %f) - call void @foob_Foo_test2(ptr %f, i32 123) + call void @foob.Foo_test(ptr %f) + call void @foob.Foo_test2(ptr %f, i32 123) ret void } diff --git a/test/test_suite/module/module_section_export.c3t b/test/test_suite/module/module_section_export.c3t index e325b6d41..37e75a5a8 100644 --- a/test/test_suite/module/module_section_export.c3t +++ b/test/test_suite/module/module_section_export.c3t @@ -18,11 +18,12 @@ int d @private; /* #expect: test.ll + @TEST_a = local_unnamed_addr global i32 0, align 4 -@TEST_b = protected unnamed_addr global i32 0, align 4 +@TEST.b = protected unnamed_addr global i32 0, align 4 @TEST_c = local_unnamed_addr global i32 0, align 4 @TEST_d = local_unnamed_addr global i32 0, align 4 -define internal void @TEST_hello() +define internal void @TEST.hello() define void @TEST_hello2() define void @TEST_helloe() \ No newline at end of file diff --git a/test/test_suite/overloading/set_overload.c3t b/test/test_suite/overloading/set_overload.c3t index 69f60e247..402b9f5ae 100644 --- a/test/test_suite/overloading/set_overload.c3t +++ b/test/test_suite/overloading/set_overload.c3t @@ -14,11 +14,11 @@ fn void main() /* #expect: test.ll -define void @test_main() #0 { +define void @test.main() #0 { entry: %map = alloca %HashMap, align 8 call void @llvm.memset.p0.i64(ptr align 8 %map, i8 0, i64 40, i1 false) - %0 = call i8 @"std_collections_map$$sa$char.int_HashMap_set"(ptr %map, ptr @.str, i64 5, i32 4) - %1 = call i8 @"std_collections_map$$sa$char.int_HashMap_set"(ptr %map, ptr @.str.1, i64 3, i32 5) + %0 = call i8 @"std_collections_map$$sa$char.int.HashMap_set"(ptr %map, ptr @.str, i64 5, i32 4) + %1 = call i8 @"std_collections_map$$sa$char.int.HashMap_set"(ptr %map, ptr @.str.1, i64 3, i32 5) ret void } \ No newline at end of file diff --git a/test/test_suite/pointers/array_pointer_decay.c3t b/test/test_suite/pointers/array_pointer_decay.c3t index 2cf06ed23..b7c1840a4 100644 --- a/test/test_suite/pointers/array_pointer_decay.c3t +++ b/test/test_suite/pointers/array_pointer_decay.c3t @@ -21,7 +21,7 @@ fn void main() /* #expect: foo.ll -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %x = alloca [3 x i32], align 4 %y = alloca ptr, align 8 diff --git a/test/test_suite/pointers/const_pointer.c3t b/test/test_suite/pointers/const_pointer.c3t index cb39fb26e..f8e0b169b 100644 --- a/test/test_suite/pointers/const_pointer.c3t +++ b/test/test_suite/pointers/const_pointer.c3t @@ -10,7 +10,7 @@ void*[3] data @private = { &foo, &bar, &xx }; /* #expect: const_pointer.ll -@const_pointer_foo = protected global double 1.700000e+01, align 8 -@const_pointer_bar = protected global double 1.200000e+01, align 8 -@const_pointer_xx = protected global float 1.200000e+01, align 4 -@const_pointer_data = protected unnamed_addr global [3 x ptr] [ptr @const_pointer_foo, ptr @const_pointer_bar, ptr @const_pointer_xx], align 16 +@const_pointer.foo = protected global double 1.700000e+01, align 8 +@const_pointer.bar = protected global double 1.200000e+01, align 8 +@const_pointer.xx = protected global float 1.200000e+01, align 4 +@const_pointer.data = protected unnamed_addr global [3 x ptr] [ptr @const_pointer.foo, ptr @const_pointer.bar, ptr @const_pointer.xx], align 16 diff --git a/test/test_suite/pointers/pointer_index.c3t b/test/test_suite/pointers/pointer_index.c3t index d9be2607a..5c01c7fc9 100644 --- a/test/test_suite/pointers/pointer_index.c3t +++ b/test/test_suite/pointers/pointer_index.c3t @@ -24,7 +24,7 @@ fn void test3(long* x) // #expect: pointer_index.ll -define void @pointer_index_test1(ptr %0) #0 { +define void @pointer_index.test1(ptr %0) #0 { entry: %a = alloca i32, align 4 %b = alloca i32, align 4 @@ -45,7 +45,7 @@ entry: } ; Function Attrs: nounwind -define void @pointer_index_test2(ptr %0) #0 { +define void @pointer_index.test2(ptr %0) #0 { entry: %a = alloca i8, align 1 %b = alloca i8, align 1 @@ -61,7 +61,7 @@ entry: ret void } -define void @pointer_index_test3(ptr %0) #0 { +define void @pointer_index.test3(ptr %0) #0 { entry: %a = alloca i64, align 8 %b = alloca i64, align 8 diff --git a/test/test_suite/pointers/subarray_variant_to_ptr.c3t b/test/test_suite/pointers/subarray_variant_to_ptr.c3t index 19dc067f0..a7e0f7238 100644 --- a/test/test_suite/pointers/subarray_variant_to_ptr.c3t +++ b/test/test_suite/pointers/subarray_variant_to_ptr.c3t @@ -31,7 +31,7 @@ fn void main() @"ct$int" = linkonce constant %.introspect { i8 2, i64 4, i64 0, i64 0, [0 x i64] zeroinitializer }, align 8 -define void @foo_test1(i64 %0, ptr %1) #0 { +define void @foo.test1(i64 %0, ptr %1) #0 { entry: %z = alloca %variant, align 8 %w = alloca ptr, align 8 @@ -47,7 +47,7 @@ entry: ret void } -define void @foo_test2(ptr %0, i64 %1) #0 { +define void @foo.test2(ptr %0, i64 %1) #0 { entry: %z = alloca %"int[]", align 8 %w = alloca ptr, align 8 @@ -63,7 +63,7 @@ entry: ret void } -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %x = alloca i32, align 4 %y = alloca i32, align 4 @@ -79,8 +79,8 @@ entry: %lo = load i64, ptr %2, align 8 %3 = getelementptr inbounds { i64, ptr }, ptr %taddr, i32 0, i32 1 %hi = load ptr, ptr %3, align 8 - call void @foo_test1(i64 %lo, ptr %hi) + call void @foo.test1(i64 %lo, ptr %hi) %4 = getelementptr inbounds [2 x i32], ptr %w, i64 0, i64 0 - call void @foo_test2(ptr %4, i64 2) + call void @foo.test2(ptr %4, i64 2) ret void } \ No newline at end of file diff --git a/test/test_suite/safe/deref.c3t b/test/test_suite/safe/deref.c3t index 05bc2d220..3f92c6fd8 100644 --- a/test/test_suite/safe/deref.c3t +++ b/test/test_suite/safe/deref.c3t @@ -10,7 +10,7 @@ fn void main() /* #expect: foo.ll -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %x = alloca ptr, align 8 %y = alloca i32, align 4 @@ -20,7 +20,7 @@ entry: br i1 %checknull, label %panic, label %checkok panic: ; preds = %entry - %1 = load ptr, ptr @std_core_builtin_panic, align 8 + %1 = load ptr, ptr @std_core_builtin.panic, align 8 call void %1(ptr @.panic_msg, i64 27, ptr @.file, i64 8, ptr @.func, i64 4, i32 6) br label %checkok diff --git a/test/test_suite/slices/slice_assign.c3t b/test/test_suite/slices/slice_assign.c3t index 13df9b6f6..5e26d4771 100644 --- a/test/test_suite/slices/slice_assign.c3t +++ b/test/test_suite/slices/slice_assign.c3t @@ -23,7 +23,7 @@ fn void main() ; Function Attrs: nounwind declare void @printf(ptr, ...) #0 -define void @test_main() #0 { +define void @test.main() #0 { entry: %x = alloca [8 x i32], align 16 %.anon = alloca i64, align 8 @@ -84,6 +84,6 @@ exit: ; preds = %cond ; Function Attrs: nounwind define i32 @main(i32 %0, ptr %1) #0 { entry: - call void @test_main() + call void @test.main() ret i32 0 } diff --git a/test/test_suite/slices/slice_to_slice_assign.c3t b/test/test_suite/slices/slice_to_slice_assign.c3t index 8917819c7..d985dc886 100644 --- a/test/test_suite/slices/slice_to_slice_assign.c3t +++ b/test/test_suite/slices/slice_to_slice_assign.c3t @@ -20,7 +20,7 @@ fn void main() } /* #expect: test.ll -define void @test_main() #0 { +define void @test.main() #0 { entry: %z = alloca [7 x i32], align 16 %y = alloca [6 x i32], align 16 @@ -66,7 +66,7 @@ entry: %15 = insertvalue %variant %14, i64 ptrtoint (ptr @"ct$a7$int" to i64), 1 %16 = getelementptr inbounds [2 x %variant], ptr %varargslots, i64 0, i64 1 store %variant %15, ptr %16, align 16 - %17 = call i64 @std_io_printfn(ptr %retparam, ptr @.str, i64 5, ptr %varargslots, i64 2) + %17 = call i64 @std_io.printfn(ptr %retparam, ptr @.str, i64 5, ptr %varargslots, i64 2) %18 = getelementptr inbounds [7 x i32], ptr %z, i64 0, i64 5 %19 = insertvalue %"int[]" undef, ptr %18, 0 %20 = insertvalue %"int[]" %19, i64 2, 1 @@ -88,7 +88,7 @@ entry: %33 = insertvalue %variant %32, i64 ptrtoint (ptr @"ct$a7$int" to i64), 1 %34 = getelementptr inbounds [2 x %variant], ptr %varargslots3, i64 0, i64 1 store %variant %33, ptr %34, align 16 - %35 = call i64 @std_io_printfn(ptr %retparam2, ptr @.str.1, i64 5, ptr %varargslots3, i64 2) + %35 = call i64 @std_io.printfn(ptr %retparam2, ptr @.str.1, i64 5, ptr %varargslots3, i64 2) %36 = getelementptr inbounds [1 x %"int[]"], ptr %literal, i64 0, i64 0 %37 = getelementptr inbounds [1 x i32], ptr %literal4, i64 0, i64 0 store i32 1, ptr %37, align 4 @@ -111,7 +111,7 @@ entry: %49 = insertvalue %variant %48, i64 ptrtoint (ptr @"ct$sa$sa$int" to i64), 1 %50 = getelementptr inbounds [1 x %variant], ptr %varargslots8, i64 0, i64 0 store %variant %49, ptr %50, align 16 - %51 = call i64 @std_io_printfn(ptr %retparam7, ptr @.str.2, i64 2, ptr %varargslots8, i64 1) + %51 = call i64 @std_io.printfn(ptr %retparam7, ptr @.str.2, i64 2, ptr %varargslots8, i64 1) %52 = load %"int[][]", ptr %b, align 8 %53 = extractvalue %"int[][]" %52, 0 %ptroffset = getelementptr inbounds %"int[]", ptr %53, i64 0 @@ -133,7 +133,7 @@ entry: %66 = insertvalue %variant %65, i64 ptrtoint (ptr @"ct$sa$sa$int" to i64), 1 %67 = getelementptr inbounds [1 x %variant], ptr %varargslots12, i64 0, i64 0 store %variant %66, ptr %67, align 16 - %68 = call i64 @std_io_printfn(ptr %retparam11, ptr @.str.3, i64 2, ptr %varargslots12, i64 1) + %68 = call i64 @std_io.printfn(ptr %retparam11, ptr @.str.3, i64 2, ptr %varargslots12, i64 1) %69 = getelementptr inbounds [6 x i32], ptr %y, i64 0, i64 2 %70 = insertvalue %"int[]" undef, ptr %69, 0 %71 = insertvalue %"int[]" %70, i64 3, 1 @@ -145,6 +145,6 @@ entry: %75 = insertvalue %variant %74, i64 ptrtoint (ptr @"ct$sa$sa$int" to i64), 1 %76 = getelementptr inbounds [1 x %variant], ptr %varargslots15, i64 0, i64 0 store %variant %75, ptr %76, align 16 - %77 = call i64 @std_io_printfn(ptr %retparam14, ptr @.str.4, i64 2, ptr %varargslots15, i64 1) + %77 = call i64 @std_io.printfn(ptr %retparam14, ptr @.str.4, i64 2, ptr %varargslots15, i64 1) ret void } diff --git a/test/test_suite/slices/slice_to_slice_vector_assign.c3t b/test/test_suite/slices/slice_to_slice_vector_assign.c3t index 4cd62f017..6b165068c 100644 --- a/test/test_suite/slices/slice_to_slice_vector_assign.c3t +++ b/test/test_suite/slices/slice_to_slice_vector_assign.c3t @@ -21,7 +21,7 @@ fn void main() /* #expect: test.ll -define void @test_main() #0 { +define void @test.main() #0 { entry: %z = alloca <7 x i32>, align 32 %y = alloca <6 x i32>, align 32 @@ -67,7 +67,7 @@ entry: %15 = insertvalue %variant %14, i64 ptrtoint (ptr @"ct$v7$int" to i64), 1 %16 = getelementptr inbounds [2 x %variant], ptr %varargslots, i64 0, i64 1 store %variant %15, ptr %16, align 16 - %17 = call i64 @std_io_printfn(ptr %retparam, ptr @.str, i64 5, ptr %varargslots, i64 2) + %17 = call i64 @std_io.printfn(ptr %retparam, ptr @.str, i64 5, ptr %varargslots, i64 2) %18 = getelementptr inbounds <7 x i32>, ptr %z, i64 0, i64 5 %19 = insertvalue %"int[]" undef, ptr %18, 0 %20 = insertvalue %"int[]" %19, i64 2, 1 @@ -89,7 +89,7 @@ entry: %33 = insertvalue %variant %32, i64 ptrtoint (ptr @"ct$v7$int" to i64), 1 %34 = getelementptr inbounds [2 x %variant], ptr %varargslots3, i64 0, i64 1 store %variant %33, ptr %34, align 16 - %35 = call i64 @std_io_printfn(ptr %retparam2, ptr @.str.1, i64 5, ptr %varargslots3, i64 2) + %35 = call i64 @std_io.printfn(ptr %retparam2, ptr @.str.1, i64 5, ptr %varargslots3, i64 2) %36 = getelementptr inbounds [1 x %"int[]"], ptr %literal, i64 0, i64 0 %37 = getelementptr inbounds [1 x i32], ptr %literal4, i64 0, i64 0 store i32 1, ptr %37, align 4 @@ -112,7 +112,7 @@ entry: %49 = insertvalue %variant %48, i64 ptrtoint (ptr @"ct$sa$sa$int" to i64), 1 %50 = getelementptr inbounds [1 x %variant], ptr %varargslots8, i64 0, i64 0 store %variant %49, ptr %50, align 16 - %51 = call i64 @std_io_printfn(ptr %retparam7, ptr @.str.2, i64 2, ptr %varargslots8, i64 1) + %51 = call i64 @std_io.printfn(ptr %retparam7, ptr @.str.2, i64 2, ptr %varargslots8, i64 1) %52 = load %"int[][]", ptr %b, align 8 %53 = extractvalue %"int[][]" %52, 0 %ptroffset = getelementptr inbounds %"int[]", ptr %53, i64 0 @@ -134,7 +134,7 @@ entry: %66 = insertvalue %variant %65, i64 ptrtoint (ptr @"ct$sa$sa$int" to i64), 1 %67 = getelementptr inbounds [1 x %variant], ptr %varargslots12, i64 0, i64 0 store %variant %66, ptr %67, align 16 - %68 = call i64 @std_io_printfn(ptr %retparam11, ptr @.str.3, i64 2, ptr %varargslots12, i64 1) + %68 = call i64 @std_io.printfn(ptr %retparam11, ptr @.str.3, i64 2, ptr %varargslots12, i64 1) %69 = getelementptr inbounds <6 x i32>, ptr %y, i64 0, i64 2 %70 = insertvalue %"int[]" undef, ptr %69, 0 %71 = insertvalue %"int[]" %70, i64 3, 1 @@ -146,6 +146,6 @@ entry: %75 = insertvalue %variant %74, i64 ptrtoint (ptr @"ct$sa$sa$int" to i64), 1 %76 = getelementptr inbounds [1 x %variant], ptr %varargslots15, i64 0, i64 0 store %variant %75, ptr %76, align 16 - %77 = call i64 @std_io_printfn(ptr %retparam14, ptr @.str.4, i64 2, ptr %varargslots15, i64 1) + %77 = call i64 @std_io.printfn(ptr %retparam14, ptr @.str.4, i64 2, ptr %varargslots15, i64 1) ret void } diff --git a/test/test_suite/statements/comparison_widening.c3t b/test/test_suite/statements/comparison_widening.c3t index 5e873dbb8..d79f526b1 100644 --- a/test/test_suite/statements/comparison_widening.c3t +++ b/test/test_suite/statements/comparison_widening.c3t @@ -10,7 +10,7 @@ fn void test1() /* #expect: comparison_widening.ll -define void @comparison_widening_test1() #0 { +define void @comparison_widening.test1() #0 { entry: %a = alloca i8, align 1 %b = alloca i32, align 4 diff --git a/test/test_suite/statements/const_statements.c3t b/test/test_suite/statements/const_statements.c3t index 7c99ac72c..f4288e2df 100644 --- a/test/test_suite/statements/const_statements.c3t +++ b/test/test_suite/statements/const_statements.c3t @@ -9,7 +9,7 @@ fn void main() /* #expect: test.ll -define void @test_main() #0 { +define void @test.main() #0 { entry: ret void } \ No newline at end of file diff --git a/test/test_suite/statements/custom_foreach_with_ref.c3t b/test/test_suite/statements/custom_foreach_with_ref.c3t index 93c2c234f..f29445692 100644 --- a/test/test_suite/statements/custom_foreach_with_ref.c3t +++ b/test/test_suite/statements/custom_foreach_with_ref.c3t @@ -85,7 +85,7 @@ fn void main() %Foo = type { [3 x i32] } -@"ct$foo_Foo" = linkonce constant %.introspect { i8 10, i64 12, i64 0, i64 1, [0 x i64] zeroinitializer }, align 8 +@"ct$foo.Foo" = linkonce constant %.introspect { i8 10, i64 12, i64 0, i64 1, [0 x i64] zeroinitializer }, align 8 @.str = private unnamed_addr constant [11 x i8] c"getFields\0A\00", align 1 @.str.1 = private unnamed_addr constant [11 x i8] c"Call made\0A\00", align 1 @.__const = private unnamed_addr constant %Foo { [3 x i32] [i32 1, i32 5, i32 7] }, align 4 @@ -102,7 +102,7 @@ fn void main() @.str.12 = private unnamed_addr constant [7 x i8] c"%d %d\0A\00", align 1 @.str.13 = private unnamed_addr constant [7 x i8] c"%d %d\0A\00", align 1 -define void @foo_getFields(ptr noalias sret([5 x i32]) align 4 %0) #0 { +define void @foo.getFields(ptr noalias sret([5 x i32]) align 4 %0) #0 { entry: %literal = alloca [5 x i32], align 16 call void (ptr, ...) @printf(ptr @.str) @@ -120,13 +120,13 @@ entry: ret void } -define ptr @foo_call(ptr %0) #0 { +define ptr @foo.call(ptr %0) #0 { entry: call void (ptr, ...) @printf(ptr @.str.1) ret ptr %0 } -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %x = alloca %Foo, align 4 %a = alloca i32, align 4 @@ -197,7 +197,7 @@ entry: %10 = getelementptr inbounds [3 x i32], ptr %8, i64 0, i64 %sisiext4 %11 = load i32, ptr %10, align 4 call void (ptr, ...) @printf(ptr @.str.2, i32 %3, i32 %7, i32 %11) - %12 = call ptr @foo_call(ptr %x) + %12 = call ptr @foo.call(ptr %x) store ptr %12, ptr %.anon, align 8 store i32 3, ptr %.anon5, align 4 store i32 0, ptr %.anon6, align 4 @@ -385,7 +385,7 @@ loop.body58: ; preds = %loop.cond57 br label %loop.cond57 loop.exit63: ; preds = %loop.cond57 - call void @foo_getFields(ptr sret([5 x i32]) align 4 %.anon64) + call void @foo.getFields(ptr sret([5 x i32]) align 4 %.anon64) store i64 0, ptr %.anon65, align 8 br label %loop.cond66 @@ -410,7 +410,7 @@ loop.body68: ; preds = %loop.cond66 br label %loop.cond66 loop.exit72: ; preds = %loop.cond66 - call void @foo_getFields(ptr sret([5 x i32]) align 4 %sretparam) + call void @foo.getFields(ptr sret([5 x i32]) align 4 %sretparam) store ptr %sretparam, ptr %.anon73, align 8 store i64 0, ptr %.anon74, align 8 br label %loop.cond75 diff --git a/test/test_suite/statements/defer_break.c3t b/test/test_suite/statements/defer_break.c3t index 50260f094..c20d7f7ac 100644 --- a/test/test_suite/statements/defer_break.c3t +++ b/test/test_suite/statements/defer_break.c3t @@ -51,7 +51,7 @@ define i32 @main(i32 %0, ptr %1) #0 { entry: %a = alloca i32, align 4 store i32 0, ptr %a, align 4 - call void @foo_defer2() + call void @foo.defer2() %2 = load i32, ptr %a, align 4 %eq = icmp eq i32 %2, 1 br i1 %eq, label %if.then, label %if.exit @@ -60,7 +60,7 @@ if.then: ; preds = %entry br label %loop.exit if.exit: ; preds = %entry - call void @foo_defer1() + call void @foo.defer1() br label %loop.exit loop.exit: ; preds = %if.exit, %if.then @@ -76,13 +76,13 @@ loop.body: ; preds = %loop.cond br i1 %eq1, label %if.then2, label %if.exit3 if.then2: ; preds = %loop.body - call void @foo_defer4() + call void @foo.defer4() br label %loop.exit4 if.exit3: ; preds = %loop.body - call void @foo_defer6() - call void @foo_defer5() - call void @foo_defer4() + call void @foo.defer6() + call void @foo.defer5() + call void @foo.defer4() br label %loop.cond loop.exit4: ; preds = %if.then2, %loop.cond @@ -98,17 +98,17 @@ loop.body7: ; preds = %loop.cond5 br i1 %eq8, label %if.then9, label %if.exit10 if.then9: ; preds = %loop.body7 - call void @foo_defer8() + call void @foo.defer8() br label %loop.exit11 if.exit10: ; preds = %loop.body7 - call void @foo_defer10() - call void @foo_defer9() - call void @foo_defer8() + call void @foo.defer10() + call void @foo.defer9() + call void @foo.defer8() br label %loop.exit11 loop.exit11: ; preds = %if.exit10, %if.then9, %loop.cond5 - call void @foo_defer7() - call void @foo_defer3() + call void @foo.defer7() + call void @foo.defer3() ret i32 0 } \ No newline at end of file diff --git a/test/test_suite/statements/defer_break_simple.c3t b/test/test_suite/statements/defer_break_simple.c3t index ccf939509..d87e809a4 100644 --- a/test/test_suite/statements/defer_break_simple.c3t +++ b/test/test_suite/statements/defer_break_simple.c3t @@ -41,16 +41,16 @@ loop.body: ; preds = %loop.cond br i1 %eq, label %if.then, label %if.exit if.then: ; preds = %loop.body - call void @test_testA() - call void @test_testB() - call void @test_test2() + call void @test.testA() + call void @test.testB() + call void @test.test2() br label %loop.exit if.exit: ; preds = %loop.body - call void @test_test3() - call void @test_testA() - call void @test_testB() - call void @test_test2() + call void @test.test3() + call void @test.testA() + call void @test.testB() + call void @test.test2() br label %loop.cond loop.exit: ; preds = %if.then, %loop.cond diff --git a/test/test_suite/statements/defer_break_switch.c3t b/test/test_suite/statements/defer_break_switch.c3t index d70f10eb4..abec39467 100644 --- a/test/test_suite/statements/defer_break_switch.c3t +++ b/test/test_suite/statements/defer_break_switch.c3t @@ -21,7 +21,7 @@ fn void test(int i) /* #expect: defer_break_switch.ll -define void @defer_break_switch_test(i32 %0) #0 { +define void @defer_break_switch.test(i32 %0) #0 { entry: %b = alloca i8, align 1 %switch = alloca i32, align 4 @@ -42,16 +42,16 @@ switch.case: ; preds = %switch.entry br i1 %3, label %if.then, label %if.exit if.then: ; preds = %switch.case - call void @defer_break_switch_test2() + call void @defer_break_switch.test2() br label %switch.exit if.exit: ; preds = %switch.case - call void @defer_break_switch_test1() - call void @defer_break_switch_test2() + call void @defer_break_switch.test1() + call void @defer_break_switch.test2() br label %switch.exit switch.case1: ; preds = %switch.entry - call void @defer_break_switch_test1() + call void @defer_break_switch.test1() br label %switch.exit switch.exit: ; preds = %switch.case1, %if.exit, %if.then, %switch.entry diff --git a/test/test_suite/statements/defer_do_while.c3t b/test/test_suite/statements/defer_do_while.c3t index 3cd84eaae..d401502c8 100644 --- a/test/test_suite/statements/defer_do_while.c3t +++ b/test/test_suite/statements/defer_do_while.c3t @@ -13,7 +13,7 @@ fn void test() /* #expect: foo.ll -define void @foo_test() #0 { +define void @foo.test() #0 { entry: %a = alloca i32, align 4 store i32 0, ptr %a, align 4 diff --git a/test/test_suite/statements/defer_in_block.c3t b/test/test_suite/statements/defer_in_block.c3t index df2e63eed..46b3c9954 100644 --- a/test/test_suite/statements/defer_in_block.c3t +++ b/test/test_suite/statements/defer_in_block.c3t @@ -28,7 +28,7 @@ fn void main() } /* #expect: foo.ll -define void @foo_test(i32 %0) #0 { +define void @foo.test(i32 %0) #0 { entry: %x = alloca i32, align 4 store i32 %0, ptr %x, align 4 @@ -78,10 +78,10 @@ if.exit6: ; preds = %if.exit3 } ; Function Attrs: nounwind -define void @foo_main() #0 { +define void @foo.main() #0 { entry: - call void @foo_test(i32 123) - call void @foo_test(i32 1) - call void @foo_test(i32 0) + call void @foo.test(i32 123) + call void @foo.test(i32 1) + call void @foo.test(i32 0) ret void } diff --git a/test/test_suite/statements/defer_in_defer.c3t b/test/test_suite/statements/defer_in_defer.c3t index e61cfb5ad..6d9e15b73 100644 --- a/test/test_suite/statements/defer_in_defer.c3t +++ b/test/test_suite/statements/defer_in_defer.c3t @@ -22,17 +22,17 @@ fn void test_line() // #expect: defer_in_defer.ll -define void @defer_in_defer_test() #0 { +define void @defer_in_defer.test() #0 { entry: - call void @defer_in_defer_test4() - call void @defer_in_defer_test2() - call void @defer_in_defer_test3() - call void @defer_in_defer_test1() + call void @defer_in_defer.test4() + call void @defer_in_defer.test2() + call void @defer_in_defer.test3() + call void @defer_in_defer.test1() ret void } -define void @defer_in_defer_test_line() #0 { +define void @defer_in_defer.test_line() #0 { entry: - call void @defer_in_defer_test1() + call void @defer_in_defer.test1() ret void } diff --git a/test/test_suite/statements/defer_in_defer2.c3t b/test/test_suite/statements/defer_in_defer2.c3t index 173cb87e8..5de8af3a3 100644 --- a/test/test_suite/statements/defer_in_defer2.c3t +++ b/test/test_suite/statements/defer_in_defer2.c3t @@ -32,7 +32,7 @@ fn void main() /* #expect: test.ll -define void @test_test(i32 %0) #0 { +define void @test.test(i32 %0) #0 { entry: %x = alloca i32, align 4 store i32 %0, ptr %x, align 4 diff --git a/test/test_suite/statements/defer_next_switch.c3t b/test/test_suite/statements/defer_next_switch.c3t index 649c25d55..011484cd5 100644 --- a/test/test_suite/statements/defer_next_switch.c3t +++ b/test/test_suite/statements/defer_next_switch.c3t @@ -21,7 +21,7 @@ fn void test(int i) /* #expect: defer_next_switch.ll -define void @defer_next_switch_test(i32 %0) #0 { +define void @defer_next_switch.test(i32 %0) #0 { entry: %b = alloca i8, align 1 %switch = alloca i32, align 4 @@ -42,16 +42,16 @@ switch.case: ; preds = %switch.entry br i1 %3, label %if.then, label %if.exit if.then: ; preds = %switch.case - call void @defer_next_switch_test2() + call void @defer_next_switch.test2() br label %switch.case1 if.exit: ; preds = %switch.case - call void @defer_next_switch_test1() - call void @defer_next_switch_test2() + call void @defer_next_switch.test1() + call void @defer_next_switch.test2() br label %switch.exit switch.case1: ; preds = %switch.entry, %if.then - call void @defer_next_switch_test1() + call void @defer_next_switch.test1() br label %switch.exit switch.exit: ; preds = %switch.case1, %if.exit, %switch.entry diff --git a/test/test_suite/statements/defer_return.c3t b/test/test_suite/statements/defer_return.c3t index 28e12ff6e..9d9c43d6f 100644 --- a/test/test_suite/statements/defer_return.c3t +++ b/test/test_suite/statements/defer_return.c3t @@ -54,14 +54,14 @@ loop.body: ; preds = %loop.cond if.then: ; preds = %loop.body %3 = load i32, ptr %a, align 4 %add = add i32 %3, %0 - call void @test_test2() - call void @test_test1() + call void @test.test2() + call void @test.test1() ret i32 %add if.exit: ; preds = %loop.body - call void @test_test4() - call void @test_test3() - call void @test_test2() + call void @test.test4() + call void @test.test3() + call void @test.test2() br label %loop.cond loop.exit: ; preds = %loop.cond @@ -79,22 +79,22 @@ loop.body3: ; preds = %loop.cond1 if.then5: ; preds = %loop.body3 %5 = load i32, ptr %a, align 4 %add6 = add i32 %5, 2 - call void @test_test6() - call void @test_test5() - call void @test_test1() + call void @test.test6() + call void @test.test5() + call void @test.test1() ret i32 %add6 if.exit7: ; preds = %loop.body3 - call void @test_test8() - call void @test_test7() - call void @test_test6() - call void @test_test5() - call void @test_test1() + call void @test.test8() + call void @test.test7() + call void @test.test6() + call void @test.test5() + call void @test.test1() ret i32 4 loop.exit8: ; preds = %loop.cond1 %add9 = add i32 0, %0 - call void @test_test5() - call void @test_test1() + call void @test.test5() + call void @test.test1() ret i32 %add9 } \ No newline at end of file diff --git a/test/test_suite/statements/defer_with_loop.c3t b/test/test_suite/statements/defer_with_loop.c3t index 717e5f771..be69a28bc 100644 --- a/test/test_suite/statements/defer_with_loop.c3t +++ b/test/test_suite/statements/defer_with_loop.c3t @@ -29,7 +29,7 @@ fn void main() /* #expect: test.ll -define void @test_test(i32 %0) #0 { +define void @test.test(i32 %0) #0 { entry: %i = alloca i32, align 4 %i4 = alloca i32, align 4 diff --git a/test/test_suite/statements/fallthough_do.c3t b/test/test_suite/statements/fallthough_do.c3t index 65c2bfb6b..12684d13b 100644 --- a/test/test_suite/statements/fallthough_do.c3t +++ b/test/test_suite/statements/fallthough_do.c3t @@ -39,14 +39,14 @@ fn void main() @.str = private unnamed_addr constant [4 x i8] c"%d\0A\00", align 1 @.str.1 = private unnamed_addr constant [8 x i8] c"%d, %d\0A\00", align 1 -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %i = alloca i32, align 4 store i32 10, ptr %i, align 4 - %0 = call i32 @foo_test() + %0 = call i32 @foo.test() call void (ptr, ...) @printf(ptr @.str, i32 %0) %1 = load i32, ptr %i, align 4 - %2 = call i32 @foo_test() + %2 = call i32 @foo.test() call void (ptr, ...) @printf(ptr @.str.1, i32 %1, i32 %2) %3 = load i32, ptr %i, align 4 %lt = icmp slt i32 %3, 0 @@ -57,7 +57,7 @@ if.then: ; preds = %entry if.exit: ; preds = %entry %4 = load i32, ptr %i, align 4 - %5 = call i32 @foo_test() + %5 = call i32 @foo.test() call void (ptr, ...) @printf(ptr @.str.2, i32 %4, i32 %5) br label %loop.exit @@ -71,7 +71,7 @@ if.then2: ; preds = %loop.exit if.exit3: ; preds = %loop.exit %7 = load i32, ptr %i, align 4 - %8 = call i32 @foo_test() + %8 = call i32 @foo.test() call void (ptr, ...) @printf(ptr @.str.3, i32 %7, i32 %8) br label %loop.exit4 diff --git a/test/test_suite/statements/foreach_break.c3t b/test/test_suite/statements/foreach_break.c3t index 000e6b1a5..a91132c9f 100644 --- a/test/test_suite/statements/foreach_break.c3t +++ b/test/test_suite/statements/foreach_break.c3t @@ -15,7 +15,7 @@ fn void test() /* #expect: test.ll -define void @test_test() #0 { +define void @test.test() #0 { entry: %x = alloca [3 x i32], align 4 %g = alloca i32, align 4 diff --git a/test/test_suite/statements/foreach_custom.c3t b/test/test_suite/statements/foreach_custom.c3t index 2c76f8bfa..fd1b5896e 100644 --- a/test/test_suite/statements/foreach_custom.c3t +++ b/test/test_suite/statements/foreach_custom.c3t @@ -34,7 +34,7 @@ extern fn int printf(char *fmt, ...); /* #expect: test.ll ; Function Attrs: nounwind -define void @test_main() #0 { +define void @test.main() #0 { entry: %i = alloca [3 x i32], align 4 %x = alloca %Foo, align 8 @@ -87,6 +87,6 @@ declare i32 @printf(ptr, ...) #0 ; Function Attrs: nounwind define i32 @main(i32 %0, ptr %1) #0 { entry: - call void @test_main() + call void @test.main() ret i32 0 } diff --git a/test/test_suite/statements/foreach_custom_macro.c3t b/test/test_suite/statements/foreach_custom_macro.c3t index 47347644a..6a9a19b5d 100644 --- a/test/test_suite/statements/foreach_custom_macro.c3t +++ b/test/test_suite/statements/foreach_custom_macro.c3t @@ -35,12 +35,12 @@ extern fn int printf(char *fmt, ...); %Foo = type { %"int[]" } %"int[]" = type { ptr, i64 } -@"ct$foo_Foo" = linkonce constant %.introspect { i8 10, i64 16, i64 0, i64 1, [0 x i64] zeroinitializer }, align 8 +@"ct$foo.Foo" = linkonce constant %.introspect { i8 10, i64 16, i64 0, i64 1, [0 x i64] zeroinitializer }, align 8 @.__const = private unnamed_addr constant [3 x i32] [i32 1, i32 3, i32 10], align 4 @.str = private unnamed_addr constant [4 x i8] c"%d\0A\00", align 1 ; Function Attrs: nounwind -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %i = alloca [3 x i32], align 4 %x = alloca %Foo, align 8 @@ -93,6 +93,6 @@ declare i32 @printf(ptr, ...) #0 ; Function Attrs: nounwind define i32 @main(i32 %0, ptr %1) #0 { entry: - call void @foo_main() + call void @foo.main() ret i32 0 } \ No newline at end of file diff --git a/test/test_suite/statements/foreach_more_implementations.c3t b/test/test_suite/statements/foreach_more_implementations.c3t index 619b52be9..ad584d9c2 100644 --- a/test/test_suite/statements/foreach_more_implementations.c3t +++ b/test/test_suite/statements/foreach_more_implementations.c3t @@ -40,7 +40,7 @@ fn void main() /* #expect: test.ll -define void @test_main() #0 { +define void @test.main() #0 { entry: %x = alloca [2 x i32], align 4 %v = alloca %Vector, align 8 @@ -93,7 +93,7 @@ loop.body: ; preds = %loop.cond %13 = insertvalue %variant %12, i64 ptrtoint (ptr @"ct$int" to i64), 1 %14 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %13, ptr %14, align 16 - %15 = call i64 @std_io_printf(ptr %retparam, ptr @.str, i64 3, ptr %varargslots, i64 1) + %15 = call i64 @std_io.printf(ptr %retparam, ptr @.str, i64 3, ptr %varargslots, i64 1) %16 = load ptr, ptr %ref, align 8 %17 = load i32, ptr %16, align 4 %add = add i32 %17, 2 @@ -132,7 +132,7 @@ loop.body9: ; preds = %loop.cond7 %30 = insertvalue %variant %29, i64 ptrtoint (ptr @"ct$int" to i64), 1 %31 = getelementptr inbounds [1 x %variant], ptr %varargslots14, i64 0, i64 0 store %variant %30, ptr %31, align 16 - %32 = call i64 @std_io_printf(ptr %retparam13, ptr @.str.1, i64 3, ptr %varargslots14, i64 1) + %32 = call i64 @std_io.printf(ptr %retparam13, ptr @.str.1, i64 3, ptr %varargslots14, i64 1) %33 = load i64, ptr %.anon6, align 8 %add15 = add i64 %33, 1 store i64 %add15, ptr %.anon6, align 8 diff --git a/test/test_suite/statements/foreach_r_break.c3t b/test/test_suite/statements/foreach_r_break.c3t index a626decf6..2813f5f36 100644 --- a/test/test_suite/statements/foreach_r_break.c3t +++ b/test/test_suite/statements/foreach_r_break.c3t @@ -16,7 +16,7 @@ fn void test() /* #expect: test.ll ; Function Attrs: nounwind -define void @test_test() #0 { +define void @test.test() #0 { entry: %x = alloca [3 x i32], align 4 %g = alloca i32, align 4 diff --git a/test/test_suite/statements/foreach_r_custom.c3t b/test/test_suite/statements/foreach_r_custom.c3t index 9540756fa..3418df5d4 100644 --- a/test/test_suite/statements/foreach_r_custom.c3t +++ b/test/test_suite/statements/foreach_r_custom.c3t @@ -34,7 +34,7 @@ extern fn int printf(char *fmt, ...); /* #expect: test.ll ; Function Attrs: nounwind -define void @test_main() #0 { +define void @test.main() #0 { entry: %i = alloca [3 x i32], align 4 %x = alloca %Foo, align 8 @@ -87,6 +87,6 @@ declare i32 @printf(ptr, ...) #0 ; Function Attrs: nounwind define i32 @main(i32 %0, ptr %1) #0 { entry: - call void @test_main() + call void @test.main() ret i32 0 } diff --git a/test/test_suite/statements/foreach_r_custom_macro.c3t b/test/test_suite/statements/foreach_r_custom_macro.c3t index 7133b7456..6f9c250d1 100644 --- a/test/test_suite/statements/foreach_r_custom_macro.c3t +++ b/test/test_suite/statements/foreach_r_custom_macro.c3t @@ -33,7 +33,7 @@ extern fn int printf(char *fmt, ...); /* #expect: test.ll ; Function Attrs: nounwind -define void @test_main() #0 { +define void @test.main() #0 { entry: %i = alloca [3 x i32], align 4 %x = alloca %Foo, align 8 @@ -86,6 +86,6 @@ declare i32 @printf(ptr, ...) #0 ; Function Attrs: nounwind define i32 @main(i32 %0, ptr %1) #0 { entry: - call void @test_main() + call void @test.main() ret i32 0 } diff --git a/test/test_suite/statements/if_tests.c3t b/test/test_suite/statements/if_tests.c3t index 472808f28..5ed75c81c 100644 --- a/test/test_suite/statements/if_tests.c3t +++ b/test/test_suite/statements/if_tests.c3t @@ -28,7 +28,7 @@ fn void test3(int x) // #expect: iftest.ll -define void @iftest_test1(i32 %0) #0 { +define void @iftest.test1(i32 %0) #0 { entry: %x = alloca i32, align 4 store i32 %0, ptr %x, align 4 @@ -46,13 +46,13 @@ if.exit: ; preds = %if.then, %entry ret void } -define void @iftest_test2(i32 %0) #0 { +define void @iftest.test2(i32 %0) #0 { entry: %gt = icmp sgt i32 %0, 0 ret void } -define void @iftest_test3(i32 %0) #0 { +define void @iftest.test3(i32 %0) #0 { entry: %x = alloca i32, align 4 store i32 %0, ptr %x, align 4 diff --git a/test/test_suite/statements/infinite_do_while.c3t b/test/test_suite/statements/infinite_do_while.c3t index 9b461e87b..146f729a0 100644 --- a/test/test_suite/statements/infinite_do_while.c3t +++ b/test/test_suite/statements/infinite_do_while.c3t @@ -20,24 +20,24 @@ fn void main() /* #expect: test.ll -define void @test_test1() #0 { +define void @test.test1() #0 { entry: br label %loop.body loop.body: ; preds = %loop.body, %entry - call void @test_testx() + call void @test.testx() br label %loop.body loop.exit: ; No predecessors! ret void } -define void @test_test2() #0 { +define void @test.test2() #0 { entry: br label %loop.body loop.body: ; preds = %loop.body, %entry - call void @test_testx() + call void @test.testx() br label %loop.body loop.exit: ; No predecessors! diff --git a/test/test_suite/statements/labelled_continue_for.c3t b/test/test_suite/statements/labelled_continue_for.c3t index c5b3c254c..c44a7ae9d 100644 --- a/test/test_suite/statements/labelled_continue_for.c3t +++ b/test/test_suite/statements/labelled_continue_for.c3t @@ -24,7 +24,7 @@ fn void testBreak() /* #expect: labelled_continue_for.ll -define void @labelled_continue_for_testBreak() #0 { +define void @labelled_continue_for.testBreak() #0 { entry: %i = alloca i32, align 4 %j = alloca i32, align 4 @@ -50,16 +50,16 @@ loop.cond4: ; preds = %loop.body3 %lt5 = icmp slt i32 %2, 10 br i1 %lt5, label %loop.body6, label %loop.exit loop.body6: ; preds = %loop.cond4 - call void @labelled_continue_for_test() + call void @labelled_continue_for.test() br label %loop.inc loop.exit: ; preds = %loop.cond4 - call void @labelled_continue_for_errored() + call void @labelled_continue_for.errored() %3 = load i32, ptr %j, align 4 %add = add i32 %3, 1 store i32 %add, ptr %j, align 4 br label %loop.cond1 loop.exit7: ; preds = %loop.cond1 - call void @labelled_continue_for_errored() + call void @labelled_continue_for.errored() br label %loop.inc loop.inc: ; preds = %loop.exit7, %loop.body6 %4 = load i32, ptr %i, align 4 diff --git a/test/test_suite/statements/ranged_switch.c3t b/test/test_suite/statements/ranged_switch.c3t index 1dd39bef2..759a0be07 100644 --- a/test/test_suite/statements/ranged_switch.c3t +++ b/test/test_suite/statements/ranged_switch.c3t @@ -67,7 +67,7 @@ target triple = "x86_64-apple-darwin" declare void @printf(ptr, ...) #0 ; Function Attrs: nounwind -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %i = alloca i32, align 4 %switch = alloca i32, align 4 @@ -223,7 +223,7 @@ switch.exit31: ; preds = %next_if30, %switch. ; Function Attrs: nounwind define i32 @main(i32 %0, ptr %1) #0 { entry: - call void @foo_main() + call void @foo.main() ret i32 0 } diff --git a/test/test_suite/statements/simple_do.c3t b/test/test_suite/statements/simple_do.c3t index e2e4a18a3..0683288c1 100644 --- a/test/test_suite/statements/simple_do.c3t +++ b/test/test_suite/statements/simple_do.c3t @@ -35,7 +35,7 @@ target triple = "x86_64-apple-darwin" @.str.1 = private unnamed_addr constant [8 x i8] c"%d, %d\0A\00", align 1 ; Function Attrs: nounwind -define i32 @foo_test() #0 { +define i32 @foo.test() #0 { entry: %0 = load i32, ptr @"test$x", align 4 %add = add i32 %0, 1 @@ -48,7 +48,7 @@ entry: declare void @printf(ptr, ...) #0 ; Function Attrs: nounwind -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %i = alloca i32, align 4 store i32 10, ptr %i, align 4 @@ -62,7 +62,7 @@ loop.cond: ; preds = %if.exit br i1 %gt, label %loop.body, label %loop.exit loop.body: ; preds = %loop.cond, %entry - %1 = call i32 @foo_test() + %1 = call i32 @foo.test() call void (ptr, ...) @printf(ptr @.str, i32 %1) %2 = load i32, ptr %i, align 4 %gt1 = icmp sgt i32 %2, 100 @@ -87,7 +87,7 @@ loop.cond2: ; preds = %if.exit5 loop.body3: ; preds = %loop.cond2, %loop.exit %4 = load i32, ptr %i, align 4 - %5 = call i32 @foo_test() + %5 = call i32 @foo.test() call void (ptr, ...) @printf(ptr @.str.1, i32 %4, i32 %5) %6 = load i32, ptr %i, align 4 %smod = srem i32 %6, 3 @@ -107,6 +107,6 @@ loop.exit6: ; preds = %if.then4, %loop.con ; Function Attrs: nounwind define i32 @main(i32 %0, ptr %1) #0 { entry: - call void @foo_main() + call void @foo.main() ret i32 0 } diff --git a/test/test_suite/statements/various_switching.c3t b/test/test_suite/statements/various_switching.c3t index a47faf638..cfd510c9c 100644 --- a/test/test_suite/statements/various_switching.c3t +++ b/test/test_suite/statements/various_switching.c3t @@ -68,7 +68,7 @@ fn void main() /* #expect: mymodule.ll -define void @mymodule_test() #0 { +define void @mymodule.test() #0 { entry: %x = alloca i32, align 4 %x.f = alloca i64, align 8 @@ -81,7 +81,7 @@ entry: %zy = alloca i32, align 4 %switch17 = alloca i32, align 4 %switch27 = alloca i8, align 1 - store i64 ptrtoint (ptr @"mymodule_ByeErr$BAR" to i64), ptr %x.f, align 8 + store i64 ptrtoint (ptr @"mymodule.ByeErr$BAR" to i64), ptr %x.f, align 8 store i64 ptrtoint (ptr @"ct$int" to i64), ptr %z, align 8 br label %testblock @@ -110,7 +110,7 @@ if.then: ; preds = %end_block switch.entry: ; preds = %if.then %2 = load i64, ptr %switch, align 8 - %eq = icmp eq i64 ptrtoint (ptr @"mymodule_HelloErr$FOO" to i64), %2 + %eq = icmp eq i64 ptrtoint (ptr @"mymodule.HelloErr$FOO" to i64), %2 br i1 %eq, label %switch.case, label %next_if switch.case: ; preds = %switch.entry @@ -118,7 +118,7 @@ switch.case: ; preds = %switch.entry br label %switch.exit next_if: ; preds = %switch.entry - %eq1 = icmp eq i64 ptrtoint (ptr @"mymodule_ByeErr$BAR" to i64), %2 + %eq1 = icmp eq i64 ptrtoint (ptr @"mymodule.ByeErr$BAR" to i64), %2 br i1 %eq1, label %switch.case2, label %next_if3 switch.case2: ; preds = %next_if diff --git a/test/test_suite/stdlib/map.c3t b/test/test_suite/stdlib/map.c3t index 02b7b7cdc..068b76903 100644 --- a/test/test_suite/stdlib/map.c3t +++ b/test/test_suite/stdlib/map.c3t @@ -59,27 +59,27 @@ fn void main() define internal void @.static_initialize.0() { entry: - %0 = load i64, ptr getelementptr inbounds (%"Entry*[]", ptr @std_io_tostring_functions, i32 0, i32 1), align 8 + %0 = load i64, ptr getelementptr inbounds (%"Entry*[]", ptr @std_io.tostring_functions, i32 0, i32 1), align 8 %not = icmp eq i64 %0, 0 br i1 %not, label %if.then, label %if.exit if.then: ; preds = %entry - %1 = load ptr, ptr @std_core_mem_thread_allocator, align 8 - call void @"std_collections_map$$typeid.p$std_io$ToStringFunction_HashMap_init"(ptr @std_io_tostring_functions, i32 64, float 7.500000e-01, ptr %1) + %1 = load ptr, ptr @std_core_mem.thread_allocator, align 8 + call void @"std_collections_map$$typeid.p$std_io$ToStringFunction.HashMap_init"(ptr @std_io.tostring_functions, i32 64, float 7.500000e-01, ptr %1) br label %if.exit if.exit: ; preds = %if.then, %entry - %2 = call i8 @"std_collections_map$$typeid.p$std_io$ToStringFunction_HashMap_set"(ptr @std_io_tostring_functions, i64 ptrtoint (ptr @"ct$test_Foo" to i64), ptr @test_Foo_to_string) + %2 = call i8 @"std_collections_map$$typeid.p$std_io$ToStringFunction.HashMap_set"(ptr @std_io.tostring_functions, i64 ptrtoint (ptr @"ct$test.Foo" to i64), ptr @test.Foo_to_string) ret void } -define { ptr, i64 } @test_Foo_to_string(ptr %0, ptr %1) #0 { +define { ptr, i64 } @test.Foo_to_string(ptr %0, ptr %1) #0 { entry: %s = alloca ptr, align 8 %retparam = alloca i64, align 8 %varargslots = alloca [2 x %variant], align 16 %result = alloca %"char[]", align 8 - %2 = call ptr @std_core_string_new_with_capacity(i64 128, ptr %1) + %2 = call ptr @std_core_string.new_with_capacity(i64 128, ptr %1) store ptr %2, ptr %s, align 8 %3 = getelementptr inbounds %Foo, ptr %0, i32 0, i32 0 %4 = insertvalue %variant undef, ptr %3, 0 @@ -91,16 +91,16 @@ entry: %9 = insertvalue %variant %8, i64 ptrtoint (ptr @"ct$p$void" to i64), 1 %10 = getelementptr inbounds [2 x %variant], ptr %varargslots, i64 0, i64 1 store %variant %9, ptr %10, align 16 - %11 = call i64 @std_core_string_VarString_printf(ptr %retparam, ptr %s, ptr @.str.12, i64 8, ptr %varargslots, i64 2) + %11 = call i64 @std_core_string.VarString_printf(ptr %retparam, ptr %s, ptr @.str.12, i64 8, ptr %varargslots, i64 2) %12 = load ptr, ptr %s, align 8 - %13 = call { ptr, i64 } @std_core_string_VarString_str(ptr %12) + %13 = call { ptr, i64 } @std_core_string.VarString_str(ptr %12) store { ptr, i64 } %13, ptr %result, align 8 %14 = load { ptr, i64 }, ptr %result, align 8 ret { ptr, i64 } %14 } ; Function Attrs: nounwind -define void @test_main() #0 { +define void @test.main() #0 { entry: %map = alloca %HashMap.0, align 8 %retparam = alloca i64, align 8 @@ -146,14 +146,14 @@ entry: %varargslots53 = alloca [1 x %variant], align 16 %result54 = alloca %"int[]", align 8 call void @llvm.memset.p0.i64(ptr align 8 %map, i8 0, i64 40, i1 false) - %0 = load ptr, ptr @std_core_mem_thread_allocator, align 8 - call void @"std_collections_map$$int.test_Foo_HashMap_init"(ptr %map, i32 16, float 7.500000e-01, ptr %0) + %0 = load ptr, ptr @std_core_mem.thread_allocator, align 8 + call void @"std_collections_map$$int.test.Foo.HashMap_init"(ptr %map, i32 16, float 7.500000e-01, ptr %0) %1 = getelementptr inbounds %HashMap.0, ptr %map, i32 0, i32 2 %2 = insertvalue %variant undef, ptr %1, 0 %3 = insertvalue %variant %2, i64 ptrtoint (ptr @"ct$uint" to i64), 1 %4 = getelementptr inbounds [1 x %variant], ptr %varargslots, i64 0, i64 0 store %variant %3, ptr %4, align 16 - %5 = call i64 @std_io_printfn(ptr %retparam, ptr @.str, i64 12, ptr %varargslots, i64 1) + %5 = call i64 @std_io.printfn(ptr %retparam, ptr @.str, i64 12, ptr %varargslots, i64 1) %6 = getelementptr inbounds %Foo, ptr %literal, i32 0, i32 0 store i32 1, ptr %6, align 8 %7 = getelementptr inbounds %Foo, ptr %literal, i32 0, i32 1 @@ -162,13 +162,13 @@ entry: %lo = load i64, ptr %8, align 8 %9 = getelementptr inbounds { i64, ptr }, ptr %literal, i32 0, i32 1 %hi = load ptr, ptr %9, align 8 - %10 = call i8 @"std_collections_map$$int.test_Foo_HashMap_set"(ptr %map, i32 1, i64 %lo, ptr %hi) + %10 = call i8 @"std_collections_map$$int.test.Foo.HashMap_set"(ptr %map, i32 1, i64 %lo, ptr %hi) %11 = getelementptr inbounds %HashMap.0, ptr %map, i32 0, i32 2 %12 = insertvalue %variant undef, ptr %11, 0 %13 = insertvalue %variant %12, i64 ptrtoint (ptr @"ct$uint" to i64), 1 %14 = getelementptr inbounds [1 x %variant], ptr %varargslots2, i64 0, i64 0 store %variant %13, ptr %14, align 16 - %15 = call i64 @std_io_printfn(ptr %retparam1, ptr @.str.1, i64 12, ptr %varargslots2, i64 1) + %15 = call i64 @std_io.printfn(ptr %retparam1, ptr @.str.1, i64 12, ptr %varargslots2, i64 1) %16 = getelementptr inbounds %Foo, ptr %literal3, i32 0, i32 0 store i32 2, ptr %16, align 8 %17 = getelementptr inbounds %Foo, ptr %literal3, i32 0, i32 1 @@ -177,14 +177,14 @@ entry: %lo4 = load i64, ptr %18, align 8 %19 = getelementptr inbounds { i64, ptr }, ptr %literal3, i32 0, i32 1 %hi5 = load ptr, ptr %19, align 8 - %20 = call i8 @"std_collections_map$$int.test_Foo_HashMap_set"(ptr %map, i32 1, i64 %lo4, ptr %hi5) + %20 = call i8 @"std_collections_map$$int.test.Foo.HashMap_set"(ptr %map, i32 1, i64 %lo4, ptr %hi5) %21 = getelementptr inbounds %HashMap.0, ptr %map, i32 0, i32 2 %22 = insertvalue %variant undef, ptr %21, 0 %23 = insertvalue %variant %22, i64 ptrtoint (ptr @"ct$uint" to i64), 1 %24 = getelementptr inbounds [1 x %variant], ptr %varargslots7, i64 0, i64 0 store %variant %23, ptr %24, align 16 - %25 = call i64 @std_io_printfn(ptr %retparam6, ptr @.str.2, i64 12, ptr %varargslots7, i64 1) - %26 = call i64 @"std_collections_map$$int.test_Foo_HashMap_get"(ptr %retparam10, ptr %map, i32 1) + %25 = call i64 @std_io.printfn(ptr %retparam6, ptr @.str.2, i64 12, ptr %varargslots7, i64 1) + %26 = call i64 @"std_collections_map$$int.test.Foo.HashMap_get"(ptr %retparam10, ptr %map, i32 1) %not_err = icmp eq i64 %26, 0 %27 = call i1 @llvm.expect.i1(i1 %not_err, i1 true) br i1 %27, label %after_check, label %after_check12 @@ -195,26 +195,26 @@ after_check: ; preds = %entry %30 = insertvalue %variant %29, i64 ptrtoint (ptr @"ct$int" to i64), 1 %31 = getelementptr inbounds [1 x %variant], ptr %varargslots9, i64 0, i64 0 store %variant %30, ptr %31, align 16 - %32 = call i64 @std_io_printfn(ptr %retparam8, ptr @.str.3, i64 7, ptr %varargslots9, i64 1) + %32 = call i64 @std_io.printfn(ptr %retparam8, ptr @.str.3, i64 7, ptr %varargslots9, i64 1) %not_err11 = icmp eq i64 %32, 0 %33 = call i1 @llvm.expect.i1(i1 %not_err11, i1 true) br i1 %33, label %after_check12, label %after_check12 after_check12: ; preds = %entry, %after_check, %after_check - %34 = call i8 @"std_collections_map$$int.test_Foo_HashMap_has_key"(ptr %map, i32 1) + %34 = call i8 @"std_collections_map$$int.test.Foo.HashMap_has_key"(ptr %map, i32 1) store i8 %34, ptr %taddr, align 1 %35 = insertvalue %variant undef, ptr %taddr, 0 %36 = insertvalue %variant %35, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %37 = getelementptr inbounds [1 x %variant], ptr %varargslots14, i64 0, i64 0 store %variant %36, ptr %37, align 16 - %38 = call i64 @std_io_printfn(ptr %retparam13, ptr @.str.4, i64 9, ptr %varargslots14, i64 1) - %39 = call i8 @"std_collections_map$$int.test_Foo_HashMap_has_key"(ptr %map, i32 2) + %38 = call i64 @std_io.printfn(ptr %retparam13, ptr @.str.4, i64 9, ptr %varargslots14, i64 1) + %39 = call i8 @"std_collections_map$$int.test.Foo.HashMap_has_key"(ptr %map, i32 2) store i8 %39, ptr %taddr19, align 1 %40 = insertvalue %variant undef, ptr %taddr19, 0 %41 = insertvalue %variant %40, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %42 = getelementptr inbounds [1 x %variant], ptr %varargslots18, i64 0, i64 0 store %variant %41, ptr %42, align 16 - %43 = call i64 @std_io_printfn(ptr %retparam17, ptr @.str.5, i64 9, ptr %varargslots18, i64 1) + %43 = call i64 @std_io.printfn(ptr %retparam17, ptr @.str.5, i64 9, ptr %varargslots18, i64 1) %44 = getelementptr inbounds %Foo, ptr %literal22, i32 0, i32 0 store i32 4, ptr %44, align 8 %45 = getelementptr inbounds %Foo, ptr %literal22, i32 0, i32 1 @@ -223,57 +223,57 @@ after_check12: ; preds = %entry, %after_check %lo23 = load i64, ptr %46, align 8 %47 = getelementptr inbounds { i64, ptr }, ptr %literal22, i32 0, i32 1 %hi24 = load ptr, ptr %47, align 8 - %48 = call i8 @"std_collections_map$$int.test_Foo_HashMap_set"(ptr %map, i32 7, i64 %lo23, ptr %hi24) - %49 = load ptr, ptr @std_core_mem_thread_allocator, align 8 - %50 = call { ptr, i64 } @"std_collections_map$$int.test_Foo_HashMap_value_list"(ptr %map, ptr %49) + %48 = call i8 @"std_collections_map$$int.test.Foo.HashMap_set"(ptr %map, i32 7, i64 %lo23, ptr %hi24) + %49 = load ptr, ptr @std_core_mem.thread_allocator, align 8 + %50 = call { ptr, i64 } @"std_collections_map$$int.test.Foo.HashMap_value_list"(ptr %map, ptr %49) store { ptr, i64 } %50, ptr %result, align 8 %51 = insertvalue %variant undef, ptr %result, 0 - %52 = insertvalue %variant %51, i64 ptrtoint (ptr @"ct$sa$test_Foo" to i64), 1 + %52 = insertvalue %variant %51, i64 ptrtoint (ptr @"ct$sa$test.Foo" to i64), 1 %53 = getelementptr inbounds [1 x %variant], ptr %varargslots26, i64 0, i64 0 store %variant %52, ptr %53, align 16 - %54 = call i64 @std_io_printfn(ptr %retparam25, ptr @.str.6, i64 10, ptr %varargslots26, i64 1) + %54 = call i64 @std_io.printfn(ptr %retparam25, ptr @.str.6, i64 10, ptr %varargslots26, i64 1) call void @llvm.memset.p0.i64(ptr align 8 %map2, i8 0, i64 40, i1 false) - %55 = load ptr, ptr @std_core_mem_thread_allocator, align 8 - call void @"std_collections_map$$int.double_HashMap_init"(ptr %map2, i32 16, float 7.500000e-01, ptr %55) - %56 = call i8 @"std_collections_map$$int.double_HashMap_set"(ptr %map2, i32 4, double 1.300000e+00) - %57 = call i8 @"std_collections_map$$int.double_HashMap_has_value"(ptr %map2, double 1.300000e+00) + %55 = load ptr, ptr @std_core_mem.thread_allocator, align 8 + call void @"std_collections_map$$int.double.HashMap_init"(ptr %map2, i32 16, float 7.500000e-01, ptr %55) + %56 = call i8 @"std_collections_map$$int.double.HashMap_set"(ptr %map2, i32 4, double 1.300000e+00) + %57 = call i8 @"std_collections_map$$int.double.HashMap_has_value"(ptr %map2, double 1.300000e+00) store i8 %57, ptr %taddr31, align 1 %58 = insertvalue %variant undef, ptr %taddr31, 0 %59 = insertvalue %variant %58, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %60 = getelementptr inbounds [1 x %variant], ptr %varargslots30, i64 0, i64 0 store %variant %59, ptr %60, align 16 - %61 = call i64 @std_io_printfn(ptr %retparam29, ptr @.str.7, i64 12, ptr %varargslots30, i64 1) - %62 = call i8 @"std_collections_map$$int.double_HashMap_has_value"(ptr %map2, double 1.200000e+00) + %61 = call i64 @std_io.printfn(ptr %retparam29, ptr @.str.7, i64 12, ptr %varargslots30, i64 1) + %62 = call i8 @"std_collections_map$$int.double.HashMap_has_value"(ptr %map2, double 1.200000e+00) store i8 %62, ptr %taddr36, align 1 %63 = insertvalue %variant undef, ptr %taddr36, 0 %64 = insertvalue %variant %63, i64 ptrtoint (ptr @"ct$bool" to i64), 1 %65 = getelementptr inbounds [1 x %variant], ptr %varargslots35, i64 0, i64 0 store %variant %64, ptr %65, align 16 - %66 = call i64 @std_io_printfn(ptr %retparam34, ptr @.str.8, i64 12, ptr %varargslots35, i64 1) - %67 = call i8 @"std_collections_map$$int.double_HashMap_set"(ptr %map2, i32 100, double 3.400000e+00) - %68 = load ptr, ptr @std_core_mem_thread_allocator, align 8 - %69 = call { ptr, i64 } @"std_collections_map$$int.double_HashMap_key_list"(ptr %map2, ptr %68) + %66 = call i64 @std_io.printfn(ptr %retparam34, ptr @.str.8, i64 12, ptr %varargslots35, i64 1) + %67 = call i8 @"std_collections_map$$int.double.HashMap_set"(ptr %map2, i32 100, double 3.400000e+00) + %68 = load ptr, ptr @std_core_mem.thread_allocator, align 8 + %69 = call { ptr, i64 } @"std_collections_map$$int.double.HashMap_key_list"(ptr %map2, ptr %68) store { ptr, i64 } %69, ptr %result41, align 8 %70 = insertvalue %variant undef, ptr %result41, 0 %71 = insertvalue %variant %70, i64 ptrtoint (ptr @"ct$sa$int" to i64), 1 %72 = getelementptr inbounds [1 x %variant], ptr %varargslots40, i64 0, i64 0 store %variant %71, ptr %72, align 16 - %73 = call i64 @std_io_printfn(ptr %retparam39, ptr @.str.9, i64 2, ptr %varargslots40, i64 1) - %74 = load ptr, ptr @std_core_mem_thread_allocator, align 8 - %75 = call { ptr, i64 } @"std_collections_map$$int.double_HashMap_value_list"(ptr %map2, ptr %74) + %73 = call i64 @std_io.printfn(ptr %retparam39, ptr @.str.9, i64 2, ptr %varargslots40, i64 1) + %74 = load ptr, ptr @std_core_mem.thread_allocator, align 8 + %75 = call { ptr, i64 } @"std_collections_map$$int.double.HashMap_value_list"(ptr %map2, ptr %74) store { ptr, i64 } %75, ptr %result46, align 8 %76 = insertvalue %variant undef, ptr %result46, 0 %77 = insertvalue %variant %76, i64 ptrtoint (ptr @"ct$sa$double" to i64), 1 %78 = getelementptr inbounds [1 x %variant], ptr %varargslots45, i64 0, i64 0 store %variant %77, ptr %78, align 16 - %79 = call i64 @std_io_printfn(ptr %retparam44, ptr @.str.10, i64 2, ptr %varargslots45, i64 1) - %80 = load ptr, ptr @std_core_mem_thread_temp_allocator, align 8 + %79 = call i64 @std_io.printfn(ptr %retparam44, ptr @.str.10, i64 2, ptr %varargslots45, i64 1) + %80 = load ptr, ptr @std_core_mem.thread_temp_allocator, align 8 %not = icmp eq ptr %80, null br i1 %not, label %if.then, label %if.exit if.then: ; preds = %after_check12 - %81 = load ptr, ptr @std_core_mem_thread_allocator, align 8 - %82 = call i64 @std_core_mem_allocator_new_temp(ptr %retparam49, i64 262144, ptr %81) + %81 = load ptr, ptr @std_core_mem.thread_allocator, align 8 + %82 = call i64 @std_core_mem_allocator.new_temp(ptr %retparam49, i64 262144, ptr %81) %not_err50 = icmp eq i64 %82, 0 %83 = call i1 @llvm.expect.i1(i1 %not_err50, i1 true) br i1 %83, label %after_check51, label %assign_optional @@ -287,37 +287,37 @@ after_check51: ; preds = %if.then br label %noerr_block panic_block: ; preds = %assign_optional - %85 = load ptr, ptr @std_core_builtin_panic, align 8 + %85 = load ptr, ptr @std_core_builtin.panic, align 8 call void %85(ptr @.panic_msg, i64 27, ptr @.file, i64 6, ptr @.func unreachable noerr_block: ; preds = %after_check51 - store ptr %84, ptr @std_core_mem_thread_temp_allocator, align 8 + store ptr %84, ptr @std_core_mem.thread_temp_allocator, align 8 br label %if.exit if.exit: ; preds = %noerr_block, %after_check12 - %86 = load ptr, ptr @std_core_mem_thread_temp_allocator, align 8 + %86 = load ptr, ptr @std_core_mem.thread_temp_allocator, align 8 store ptr %86, ptr %temp, align 8 %87 = load ptr, ptr %temp, align 8 %88 = getelementptr inbounds %TempAllocator, ptr %87, i32 0, i32 3 %89 = load i64, ptr %88, align 8 store i64 %89, ptr %mark, align 8 call void @llvm.memset.p0.i64(ptr align 8 %map3, i8 0, i64 40, i1 false) - %90 = load ptr, ptr @std_core_mem_thread_allocator, align 8 - call void @"std_collections_map$$int.double_HashMap_init"(ptr %map3, i32 16, float 7.500000e-01, ptr %90) - %91 = call i8 @"std_collections_map$$int.double_HashMap_set"(ptr %map3, i32 5, double 3.200000e+00) - %92 = call i8 @"std_collections_map$$int.double_HashMap_set"(ptr %map3, i32 7, double 5.200000e+00) - %93 = load ptr, ptr @std_core_mem_thread_allocator, align 8 - %94 = call { ptr, i64 } @"std_collections_map$$int.double_HashMap_key_list"(ptr %map3, ptr %93) + %90 = load ptr, ptr @std_core_mem.thread_allocator, align 8 + call void @"std_collections_map$$int.double.HashMap_init"(ptr %map3, i32 16, float 7.500000e-01, ptr %90) + %91 = call i8 @"std_collections_map$$int.double.HashMap_set"(ptr %map3, i32 5, double 3.200000e+00) + %92 = call i8 @"std_collections_map$$int.double.HashMap_set"(ptr %map3, i32 7, double 5.200000e+00) + %93 = load ptr, ptr @std_core_mem.thread_allocator, align 8 + %94 = call { ptr, i64 } @"std_collections_map$$int.double.HashMap_key_list"(ptr %map3, ptr %93) store { ptr, i64 } %94, ptr %result54, align 8 %95 = insertvalue %variant undef, ptr %result54, 0 %96 = insertvalue %variant %95, i64 ptrtoint (ptr @"ct$sa$int" to i64), 1 %97 = getelementptr inbounds [1 x %variant], ptr %varargslots53, i64 0, i64 0 store %variant %96, ptr %97, align 16 - %98 = call i64 @std_io_printfn(ptr %retparam52, ptr @.str.11, i64 2, ptr %varargslots53, i64 1) + %98 = call i64 @std_io.printfn(ptr %retparam52, ptr @.str.11, i64 2, ptr %varargslots53, i64 1) %99 = load ptr, ptr %temp, align 8 %100 = getelementptr inbounds %TempAllocator, ptr %99, i32 0, i32 0 %101 = load i64, ptr %mark, align 8 - call void @std_core_mem_allocator_Allocator_reset(ptr %100, i64 %101) + call void @std_core_mem_allocator.Allocator_reset(ptr %100, i64 %101) ret void } diff --git a/test/test_suite/strings/literal_to_subarray.c3t b/test/test_suite/strings/literal_to_subarray.c3t index 4a7efe479..77580f172 100644 --- a/test/test_suite/strings/literal_to_subarray.c3t +++ b/test/test_suite/strings/literal_to_subarray.c3t @@ -12,11 +12,11 @@ fn void test() %"char[]" = type { ptr, i64 } @.str = private unnamed_addr constant [6 x i8] c"hello\00", align 1 -@literal_to_subarray_y = local_unnamed_addr global %"char[]" { ptr @.str, i64 5 }, align 8 +@literal_to_subarray.y = local_unnamed_addr global %"char[]" { ptr @.str, i64 5 }, align 8 @.str.1 = private unnamed_addr constant [6 x i8] c"world\00", align 1 ; Function Attrs: nounwind -define void @literal_to_subarray_test() #0 { +define void @literal_to_subarray.test() #0 { entry: %x = alloca %"char[]", align 8 store %"char[]" { ptr @.str.1, i64 5 }, ptr %x, align 8 diff --git a/test/test_suite/strings/string_escape.c3t b/test/test_suite/strings/string_escape.c3t index 448a0a796..e926a940a 100644 --- a/test/test_suite/strings/string_escape.c3t +++ b/test/test_suite/strings/string_escape.c3t @@ -8,7 +8,7 @@ fn void main() @.str = private unnamed_addr constant [18 x i8] c"Hello\00 world! now\00", align 1 -define void @string_escape_main() #0 { +define void @string_escape.main() #0 { entry: %s = alloca ptr, align 8 store ptr @.str, ptr %s, align 8 @@ -17,6 +17,6 @@ entry: define i32 @main(i32 %0, ptr %1) #0 { entry: - call void @string_escape_main() + call void @string_escape.main() ret i32 0 } \ No newline at end of file diff --git a/test/test_suite/strings/string_len.c3t b/test/test_suite/strings/string_len.c3t index e4594a8ea..8d76b2898 100644 --- a/test/test_suite/strings/string_len.c3t +++ b/test/test_suite/strings/string_len.c3t @@ -4,4 +4,4 @@ int i = "123".len; /* #expect: string_len.ll -@string_len_i = local_unnamed_addr global i32 3, align 4 \ No newline at end of file +@string_len.i = local_unnamed_addr global i32 3, align 4 \ No newline at end of file diff --git a/test/test_suite/struct/nested_struct_init.c3t b/test/test_suite/struct/nested_struct_init.c3t index fcb8e549c..10e7b697b 100644 --- a/test/test_suite/struct/nested_struct_init.c3t +++ b/test/test_suite/struct/nested_struct_init.c3t @@ -38,18 +38,18 @@ fn void main() %Matrix2x2_b = type { %.anon.1 } %.anon.1 = type { [4 x float] } -@"ct$foo_$anon" = linkonce constant %.introspect { i8 10, i64 16, i64 0, i64 4, [0 x i64] zeroinitializer }, align 8 -@"ct$foo_$anon.3" = linkonce constant %.introspect { i8 11, i64 16, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 -@"ct$foo_Matrix2x2" = linkonce constant %.introspect { i8 10, i64 16, i64 0, i64 1, [0 x i64] zeroinitializer }, align 8 -@"ct$foo_$anon.6" = linkonce constant %.introspect { i8 10, i64 16, i64 0, i64 4, [0 x i64] zeroinitializer }, align 8 -@"ct$foo_$anon.7" = linkonce constant %.introspect { i8 11, i64 16, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 -@"ct$foo_Matrix2x2_b" = linkonce constant %.introspect { i8 10, i64 16, i64 0, i64 1, [0 x i64] zeroinitializer }, align 8 +@"ct$foo.$anon" = linkonce constant %.introspect { i8 10, i64 16, i64 0, i64 4, [0 x i64] zeroinitializer }, align 8 +@"ct$foo.$anon.3" = linkonce constant %.introspect { i8 11, i64 16, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 +@"ct$foo.Matrix2x2" = linkonce constant %.introspect { i8 10, i64 16, i64 0, i64 1, [0 x i64] zeroinitializer }, align 8 +@"ct$foo.$anon.6" = linkonce constant %.introspect { i8 10, i64 16, i64 0, i64 4, [0 x i64] zeroinitializer }, align 8 +@"ct$foo.$anon.7" = linkonce constant %.introspect { i8 11, i64 16, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 +@"ct$foo.Matrix2x2_b" = linkonce constant %.introspect { i8 10, i64 16, i64 0, i64 1, [0 x i64] zeroinitializer }, align 8 @.__const = private unnamed_addr constant %Matrix2x2 { %.anon { %.anon.0 { float 1.000000e+00, float 2.000000e+00, float 3.000000e+00, float 4.000000e+00 } } }, align 4 @.__const.8 = private unnamed_addr constant %Matrix2x2_b { %.anon.1 { [4 x float] [float 1.000000e+00, float 2.000000e+00, float 3.000000e+00, float 4.000000e+00] } }, align 4 @.str = private unnamed_addr constant [13 x i8] c"%f %f %f %f\0A\00", align 1 ; Function Attrs: nounwind -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %m = alloca %Matrix2x2, align 4 %m2 = alloca %Matrix2x2_b, align 4 diff --git a/test/test_suite/struct/nested_struct_union_init.c3t b/test/test_suite/struct/nested_struct_union_init.c3t index 74da5fe7c..e4dc71aee 100644 --- a/test/test_suite/struct/nested_struct_union_init.c3t +++ b/test/test_suite/struct/nested_struct_union_init.c3t @@ -62,7 +62,7 @@ fn void main() %.anon = type { %.anon.0 } %.anon.0 = type { float, float, float, float, float, float, float, float, float } -define void @foob_main() #0 { +define void @foob.main() #0 { entry: %x = alloca %Matrix3x3, align 4 %m = alloca %Matrix2x2, align 4 diff --git a/test/test_suite/struct/simple_struct.c3t b/test/test_suite/struct/simple_struct.c3t index e7610fc32..e2fc9b4fa 100644 --- a/test/test_suite/struct/simple_struct.c3t +++ b/test/test_suite/struct/simple_struct.c3t @@ -11,4 +11,4 @@ struct Foo // #expect: test.ll %Foo = type { i32, double } -@test_a = protected unnamed_addr global %Foo zeroinitializer, align 8 \ No newline at end of file +@test.a = protected unnamed_addr global %Foo zeroinitializer, align 8 \ No newline at end of file diff --git a/test/test_suite/struct/struct_as_value.c3t b/test/test_suite/struct/struct_as_value.c3t index 4fb50eb49..2cfa1c197 100644 --- a/test/test_suite/struct/struct_as_value.c3t +++ b/test/test_suite/struct/struct_as_value.c3t @@ -16,11 +16,11 @@ fn Event test(int x) /* #expect: test.ll %Event = type { i32 } -@"ct$test_Event" = linkonce constant %.introspect { i8 10, i64 4, i64 0, i64 1, [0 x i64] zeroinitializer }, align 8 +@"ct$test.Event" = linkonce constant %.introspect { i8 10, i64 4, i64 0, i64 1, [0 x i64] zeroinitializer }, align 8 @.__const = private unnamed_addr constant %Event { i32 1 }, align 4 @.__const.1 = private unnamed_addr constant %Event { i32 2 }, align 4 -define i32 @test_test(i32 %0) #0 { +define i32 @test.test(i32 %0) #0 { entry: %foo = alloca %Event, align 4 %bar = alloca %Event, align 4 diff --git a/test/test_suite/struct/struct_as_value_aarch64.c3t b/test/test_suite/struct/struct_as_value_aarch64.c3t index a0b81ba79..adc1e52fb 100644 --- a/test/test_suite/struct/struct_as_value_aarch64.c3t +++ b/test/test_suite/struct/struct_as_value_aarch64.c3t @@ -15,7 +15,7 @@ fn Event test(int x) /* #expect: test.ll -define i32 @test_test(i32 %0) #0 { +define i32 @test.test(i32 %0) #0 { entry: %foo = alloca %Event, align 4 %bar = alloca %Event, align 4 diff --git a/test/test_suite/struct/struct_codegen.c3t b/test/test_suite/struct/struct_codegen.c3t index 9cefb4e9a..bf95b2159 100644 --- a/test/test_suite/struct/struct_codegen.c3t +++ b/test/test_suite/struct/struct_codegen.c3t @@ -16,10 +16,10 @@ fn void test1() %Point = type { i32, i32 } -@"ct$test_Point" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 +@"ct$test.Point" = linkonce constant %.introspect { i8 10, i64 8, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 @.__const = private unnamed_addr constant %Point { i32 5, i32 6 }, align 4 -define void @test_test1() #0 { +define void @test.test1() #0 { entry: %p = alloca %Point, align 4 call void @llvm.memcpy.p0.p0.i32(ptr align 4 %p, ptr align 4 @.__const, i32 8, i1 false) diff --git a/test/test_suite/struct/struct_codegen_empty.c3t b/test/test_suite/struct/struct_codegen_empty.c3t index 71c59354a..e2ccf101d 100644 --- a/test/test_suite/struct/struct_codegen_empty.c3t +++ b/test/test_suite/struct/struct_codegen_empty.c3t @@ -23,7 +23,7 @@ fn void test() /* #expect: struct_codegen_empty.ll - define void @struct_codegen_empty_test() #0 { + define void @struct_codegen_empty.test() #0 { entry: %a = alloca %StructA, align 4 %a2 = alloca %StructA, align 4 diff --git a/test/test_suite/struct/struct_codegen_fam.c3t b/test/test_suite/struct/struct_codegen_fam.c3t index a056ab326..d44fe97fb 100644 --- a/test/test_suite/struct/struct_codegen_fam.c3t +++ b/test/test_suite/struct/struct_codegen_fam.c3t @@ -22,7 +22,7 @@ fn void test(Bar b) %Bar = type { %.anon, i32, [0 x i32] } %.anon = type { i32 } -define void @foo_test(ptr byval(%Bar) align 8 %0) #0 { +define void @foo.test(ptr byval(%Bar) align 8 %0) #0 { entry: %1 = getelementptr inbounds %Bar, ptr %0, i32 0, i32 2 %2 = getelementptr inbounds [0 x i32], ptr %1, i64 0, i64 1 diff --git a/test/test_suite/struct/struct_const_construct_simple.c3t b/test/test_suite/struct/struct_const_construct_simple.c3t index 6b709f0dd..ccd12b2eb 100644 --- a/test/test_suite/struct/struct_const_construct_simple.c3t +++ b/test/test_suite/struct/struct_const_construct_simple.c3t @@ -20,13 +20,13 @@ Foo foo8 @private = FOO7; /* #expect: structo.ll -@"ct$structo_Foo" = linkonce constant %.introspect { i8 10, i64 16, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 -@structo_x = protected unnamed_addr global i64 16, align 8 -@structo_foo1 = protected unnamed_addr global %Foo { i32 1, i64 2 }, align 8 -@structo_foo2 = protected unnamed_addr global %Foo { i32 2, i64 0 }, align 8 -@structo_foo3 = protected unnamed_addr global %Foo { i32 0, i64 3 }, align 8 -@structo_foo4 = protected unnamed_addr global %Foo { i32 4, i64 1 }, align 8 -@structo_foo5 = protected unnamed_addr global %Foo zeroinitializer, align 8 -@structo_foo6 = protected unnamed_addr global %Foo zeroinitializer, align 8 -@structo_FOO7 = protected unnamed_addr constant %Foo { i32 1, i64 2 }, align 8 -@structo_foo8 = protected unnamed_addr global %Foo { i32 1, i64 2 }, align 8 +@"ct$structo.Foo" = linkonce constant %.introspect { i8 10, i64 16, i64 0, i64 2, [0 x i64] zeroinitializer }, align 8 +@structo.x = protected unnamed_addr global i64 16, align 8 +@structo.foo1 = protected unnamed_addr global %Foo { i32 1, i64 2 }, align 8 +@structo.foo2 = protected unnamed_addr global %Foo { i32 2, i64 0 }, align 8 +@structo.foo3 = protected unnamed_addr global %Foo { i32 0, i64 3 }, align 8 +@structo.foo4 = protected unnamed_addr global %Foo { i32 4, i64 1 }, align 8 +@structo.foo5 = protected unnamed_addr global %Foo zeroinitializer, align 8 +@structo.foo6 = protected unnamed_addr global %Foo zeroinitializer, align 8 +@structo.FOO7 = protected unnamed_addr constant %Foo { i32 1, i64 2 }, align 8 +@structo.foo8 = protected unnamed_addr global %Foo { i32 1, i64 2 }, align 8 diff --git a/test/test_suite/struct/struct_pack_and_align.c3t b/test/test_suite/struct/struct_pack_and_align.c3t index a2b58755f..a6fd46bf5 100644 --- a/test/test_suite/struct/struct_pack_and_align.c3t +++ b/test/test_suite/struct/struct_pack_and_align.c3t @@ -78,14 +78,14 @@ Foo6 foo6 = { 1, 2, 3 }; %Foo5 = type { i32, [12 x i8], i8, [15 x i8] } %Foo6 = type { i32, i16, i16 } -@struct2_foo1 = local_unnamed_addr global %Foo1 <{ i64 1, i8 2, [3 x i8] undef }>, align 4 -@struct2_foo2 = local_unnamed_addr global %Foo2 <{ i8 1, i64 2, [3 x i8] undef }>, align 4 -@struct2_foo3 = local_unnamed_addr global %Foo3 <{ i8 1, i64 2, [7 x i8] undef }>, align 8 -@struct2_foo4 = local_unnamed_addr global %Foo4 <{ i8 1, i64 2 }>, align 1 -@struct2_foo5 = local_unnamed_addr global %Foo5 { i32 1, [12 x i8] undef, i8 2, [15 x i8] undef }, align 16 -@struct2_foo6 = local_unnamed_addr global %Foo6 { i32 1, i16 2, i16 3 }, align 1 +@struct2.foo1 = local_unnamed_addr global %Foo1 <{ i64 1, i8 2, [3 x i8] undef }>, align 4 +@struct2.foo2 = local_unnamed_addr global %Foo2 <{ i8 1, i64 2, [3 x i8] undef }>, align 4 +@struct2.foo3 = local_unnamed_addr global %Foo3 <{ i8 1, i64 2, [7 x i8] undef }>, align 8 +@struct2.foo4 = local_unnamed_addr global %Foo4 <{ i8 1, i64 2 }>, align 1 +@struct2.foo5 = local_unnamed_addr global %Foo5 { i32 1, [12 x i8] undef, i8 2, [15 x i8] undef }, align 16 +@struct2.foo6 = local_unnamed_addr global %Foo6 { i32 1, i16 2, i16 3 }, align 1 -define i32 @struct2_test5(i8 signext %0) #0 { +define i32 @struct2.test5(i8 signext %0) #0 { entry: %y = alloca %Foo5, align 16 call void @llvm.memset.p0.i64(ptr align 16 %y, i8 0, i64 32, i1 false) diff --git a/test/test_suite/subarrays/slice_comparison.c3t b/test/test_suite/subarrays/slice_comparison.c3t index b7e4b5d72..017abab2c 100644 --- a/test/test_suite/subarrays/slice_comparison.c3t +++ b/test/test_suite/subarrays/slice_comparison.c3t @@ -34,7 +34,7 @@ fn void main() /* #expect: mymodule.ll -define void @mymodule_main() #0 { +define void @mymodule.main() #0 { entry: %y = alloca %"char[]", align 8 %z = alloca %"char[]", align 8 diff --git a/test/test_suite/subarrays/slice_offset.c3t b/test/test_suite/subarrays/slice_offset.c3t index 5f5a740fd..37c881979 100644 --- a/test/test_suite/subarrays/slice_offset.c3t +++ b/test/test_suite/subarrays/slice_offset.c3t @@ -6,7 +6,7 @@ fn void test() /* #expect: slice_offset.ll -define void @slice_offset_test() #0 { +define void @slice_offset.test() #0 { entry: %x = alloca [3 x i32], align 4 %y = alloca %"int[]", align 8 diff --git a/test/test_suite/subarrays/slice_offset_neg_end.c3t b/test/test_suite/subarrays/slice_offset_neg_end.c3t index a3f8657e1..b7592bb09 100644 --- a/test/test_suite/subarrays/slice_offset_neg_end.c3t +++ b/test/test_suite/subarrays/slice_offset_neg_end.c3t @@ -7,7 +7,7 @@ fn void test() /* #expect: slice_offset_neg_end.ll -define void @slice_offset_neg_end_test() #0 { +define void @slice_offset_neg_end.test() #0 { entry: %x = alloca [3 x i32], align 4 %y = alloca %"int[]", align 8 diff --git a/test/test_suite/subarrays/slice_offset_neg_start.c3t b/test/test_suite/subarrays/slice_offset_neg_start.c3t index eb0a54489..cc03293be 100644 --- a/test/test_suite/subarrays/slice_offset_neg_start.c3t +++ b/test/test_suite/subarrays/slice_offset_neg_start.c3t @@ -6,7 +6,7 @@ fn void test() /* #expect: slice_offset_neg_start.ll -define void @slice_offset_neg_start_test() #0 { +define void @slice_offset_neg_start.test() #0 { entry: %x = alloca [3 x i32], align 4 %y = alloca %"int[]", align 8 diff --git a/test/test_suite/subarrays/slice_start.c3t b/test/test_suite/subarrays/slice_start.c3t index de9aa96a5..c81549952 100644 --- a/test/test_suite/subarrays/slice_start.c3t +++ b/test/test_suite/subarrays/slice_start.c3t @@ -6,7 +6,7 @@ fn void test() /* #expect: slice_start.ll -define void @slice_start_test() #0 { +define void @slice_start.test() #0 { entry: %x = alloca [3 x i32], align 4 %y = alloca %"int[]", align 8 diff --git a/test/test_suite/union/union_codegen_const.c3t b/test/test_suite/union/union_codegen_const.c3t index f99be8c5c..b46d1ec9d 100644 --- a/test/test_suite/union/union_codegen_const.c3t +++ b/test/test_suite/union/union_codegen_const.c3t @@ -13,7 +13,7 @@ Foo i = { .b = 2.3, .a = 23 }; // #expect: test.ll -@test_f = protected unnamed_addr global { i32, [4 x i8] } { i32 23, [4 x i8] undef }, align 8 -@test_g = protected unnamed_addr global %Foo { double 2.300000e+00 }, align 8 -@test_h = protected unnamed_addr global %Foo { double 2.300000e+00 }, align 8 -@test_i = local_unnamed_addr global { i32, [4 x i8] } { i32 23, [4 x i8] undef }, align 8 +@test.f = protected unnamed_addr global { i32, [4 x i8] } { i32 23, [4 x i8] undef }, align 8 +@test.g = protected unnamed_addr global %Foo { double 2.300000e+00 }, align 8 +@test.h = protected unnamed_addr global %Foo { double 2.300000e+00 }, align 8 +@test.i = local_unnamed_addr global { i32, [4 x i8] } { i32 23, [4 x i8] undef }, align 8 diff --git a/test/test_suite/union/union_codegen_empty.c3t b/test/test_suite/union/union_codegen_empty.c3t index 7acc48b84..bd460b762 100644 --- a/test/test_suite/union/union_codegen_empty.c3t +++ b/test/test_suite/union/union_codegen_empty.c3t @@ -26,7 +26,7 @@ fn void test() /* #expect: union_codegen_empty.ll source_filena -define void @union_codegen_empty_test() #0 { +define void @union_codegen_empty.test() #0 { entry: %a = alloca %UnionA, align 4 %a2 = alloca %UnionA, align 4 diff --git a/test/test_suite/union/union_codegen_overwrite_call.c3t b/test/test_suite/union/union_codegen_overwrite_call.c3t index 25a5bf02c..305840dc5 100644 --- a/test/test_suite/union/union_codegen_overwrite_call.c3t +++ b/test/test_suite/union/union_codegen_overwrite_call.c3t @@ -19,7 +19,7 @@ fn void test() /* #expect: test.ll -define void @test_test() #0 { +define void @test.test() #0 { entry: %b = alloca %UnionB, align 8 %0 = call i32 @bar() diff --git a/test/test_suite/union/union_in_struct.c3t b/test/test_suite/union/union_in_struct.c3t index 6dee64784..016259aa1 100644 --- a/test/test_suite/union/union_in_struct.c3t +++ b/test/test_suite/union/union_in_struct.c3t @@ -37,9 +37,9 @@ fn void test(Blend_Map_Entry* foo) %Blend_Map_Entry = type { %vals } %vals = type { [2 x double], [8 x i8] } -@test_foo1 = local_unnamed_addr global { i8, [4 x i8], { i32, [4 x i8] }, i32 } { i8 0, [4 x i8] undef, { i32, [4 x i8] } { i32 3, [4 x i8] undef }, i32 4 }, align 8 -@test_foo2 = local_unnamed_addr global %Foo { i8 0, %.anon { double 3.000000e+00 }, i32 4 }, align 8 -@test_a = local_unnamed_addr global { { [5 x float], [4 x i8] } } { { [5 x float], [4 x i8] } { [5 x float] [float 1.000000e+00, float 2.000000e+00, float 3.000000e+00, float 4.000000e+00, float 5.000000e+00], [4 x i8] undef } }, align 8 -@test_b = local_unnamed_addr global %Blend_Map_Entry { %vals { [2 x double] [double 6.000000e+00, double 7.000000e+00], [8 x i8] undef } }, align 8 -@test_c = local_unnamed_addr global { { { [2 x float], float, [2 x float] }, [4 x i8] } } { { { [2 x float], float, [2 x float] }, [4 x i8] } { { [2 x float], float, [2 x float] } { [2 x float] zeroinitializer, float 1.000000e+00, [2 x float] zeroinitializer }, [4 x i8] undef } }, align 8 -@test_d = local_unnamed_addr global { { [5 x float], [4 x i8] } } { { [5 x float], [4 x i8] } { [5 x float] [float 1.000000e+00, float 2.000000e+00, float 3.000000e+00, float 4.000000e+00, float 5.000000e+00], [4 x i8] undef } }, align 8 +@test.foo1 = local_unnamed_addr global { i8, [4 x i8], { i32, [4 x i8] }, i32 } { i8 0, [4 x i8] undef, { i32, [4 x i8] } { i32 3, [4 x i8] undef }, i32 4 }, align 8 +@test.foo2 = local_unnamed_addr global %Foo { i8 0, %.anon { double 3.000000e+00 }, i32 4 }, align 8 +@test.a = local_unnamed_addr global { { [5 x float], [4 x i8] } } { { [5 x float], [4 x i8] } { [5 x float] [float 1.000000e+00, float 2.000000e+00, float 3.000000e+00, float 4.000000e+00, float 5.000000e+00], [4 x i8] undef } }, align 8 +@test.b = local_unnamed_addr global %Blend_Map_Entry { %vals { [2 x double] [double 6.000000e+00, double 7.000000e+00], [8 x i8] undef } }, align 8 +@test.c = local_unnamed_addr global { { { [2 x float], float, [2 x float] }, [4 x i8] } } { { { [2 x float], float, [2 x float] }, [4 x i8] } { { [2 x float], float, [2 x float] } { [2 x float] zeroinitializer, float 1.000000e+00, [2 x float] zeroinitializer }, [4 x i8] undef } }, align 8 +@test.d = local_unnamed_addr global { { [5 x float], [4 x i8] } } { { [5 x float], [4 x i8] } { [5 x float] [float 1.000000e+00, float 2.000000e+00, float 3.000000e+00, float 4.000000e+00, float 5.000000e+00], [4 x i8] undef } }, align 8 diff --git a/test/test_suite/variant/variant_assign.c3t b/test/test_suite/variant/variant_assign.c3t index fea29d473..587336968 100644 --- a/test/test_suite/variant/variant_assign.c3t +++ b/test/test_suite/variant/variant_assign.c3t @@ -62,7 +62,7 @@ fn int main() @"ct$double" = linkonce constant %.introspect { i8 4, i64 8, i64 0, i64 0, [0 x i64] zeroinitializer }, align 8 @"ct$bool" = linkonce constant %.introspect { i8 1, i64 1, i64 0, i64 0, [0 x i64] zeroinitializer }, align 8 -define void @foo_test(i64 %0, ptr %1) #0 { +define void @foo.test(i64 %0, ptr %1) #0 { entry: %z = alloca %variant, align 8 %switch = alloca i64, align 8 @@ -114,7 +114,7 @@ switch.exit: ; preds = %switch.default, %sw ret void } -define void @foo_test2(i64 %0, ptr %1) #0 { +define void @foo.test2(i64 %0, ptr %1) #0 { entry: %y = alloca %variant, align 8 %.anon = alloca %variant, align 8 @@ -173,7 +173,7 @@ switch.exit: ; preds = %switch.default, %sw ret void } -define void @foo_test3(i64 %0, ptr %1) #0 { +define void @foo.test3(i64 %0, ptr %1) #0 { entry: %y = alloca %variant, align 8 %.anon = alloca %variant, align 8 @@ -255,7 +255,7 @@ entry: %lo = load i64, ptr %2, align 8 %3 = getelementptr inbounds { i64, ptr }, ptr %taddr1, i32 0, i32 1 %hi = load ptr, ptr %3, align 8 - call void @foo_test(i64 %lo, ptr %hi) + call void @foo.test(i64 %lo, ptr %hi) store i32 1, ptr %taddr2, align 4 %4 = insertvalue %variant undef, ptr %taddr2, 0 %5 = insertvalue %variant %4, i64 ptrtoint (ptr @"ct$int" to i64), 1 @@ -264,7 +264,7 @@ entry: %lo4 = load i64, ptr %6, align 8 %7 = getelementptr inbounds { i64, ptr }, ptr %taddr3, i32 0, i32 1 %hi5 = load ptr, ptr %7, align 8 - call void @foo_test(i64 %lo4, ptr %hi5) + call void @foo.test(i64 %lo4, ptr %hi5) store i8 1, ptr %taddr6, align 1 %8 = insertvalue %variant undef, ptr %taddr6, 0 %9 = insertvalue %variant %8, i64 ptrtoint (ptr @"ct$bool" to i64), 1 @@ -273,7 +273,7 @@ entry: %lo8 = load i64, ptr %10, align 8 %11 = getelementptr inbounds { i64, ptr }, ptr %taddr7, i32 0, i32 1 %hi9 = load ptr, ptr %11, align 8 - call void @foo_test(i64 %lo8, ptr %hi9) + call void @foo.test(i64 %lo8, ptr %hi9) store double 1.235000e+02, ptr %taddr10, align 8 %12 = insertvalue %variant undef, ptr %taddr10, 0 %13 = insertvalue %variant %12, i64 ptrtoint (ptr @"ct$double" to i64), 1 @@ -282,7 +282,7 @@ entry: %lo12 = load i64, ptr %14, align 8 %15 = getelementptr inbounds { i64, ptr }, ptr %taddr11, i32 0, i32 1 %hi13 = load ptr, ptr %15, align 8 - call void @foo_test2(i64 %lo12, ptr %hi13) + call void @foo.test2(i64 %lo12, ptr %hi13) store i32 1, ptr %taddr14, align 4 %16 = insertvalue %variant undef, ptr %taddr14, 0 %17 = insertvalue %variant %16, i64 ptrtoint (ptr @"ct$int" to i64), 1 @@ -291,7 +291,7 @@ entry: %lo16 = load i64, ptr %18, align 8 %19 = getelementptr inbounds { i64, ptr }, ptr %taddr15, i32 0, i32 1 %hi17 = load ptr, ptr %19, align 8 - call void @foo_test2(i64 %lo16, ptr %hi17) + call void @foo.test2(i64 %lo16, ptr %hi17) store i8 1, ptr %taddr18, align 1 %20 = insertvalue %variant undef, ptr %taddr18, 0 %21 = insertvalue %variant %20, i64 ptrtoint (ptr @"ct$bool" to i64), 1 @@ -300,7 +300,7 @@ entry: %lo20 = load i64, ptr %22, align 8 %23 = getelementptr inbounds { i64, ptr }, ptr %taddr19, i32 0, i32 1 %hi21 = load ptr, ptr %23, align 8 - call void @foo_test2(i64 %lo20, ptr %hi21) + call void @foo.test2(i64 %lo20, ptr %hi21) store double 1.240000e+02, ptr %taddr22, align 8 %24 = insertvalue %variant undef, ptr %taddr22, 0 %25 = insertvalue %variant %24, i64 ptrtoint (ptr @"ct$double" to i64), 1 @@ -309,7 +309,7 @@ entry: %lo24 = load i64, ptr %26, align 8 %27 = getelementptr inbounds { i64, ptr }, ptr %taddr23, i32 0, i32 1 %hi25 = load ptr, ptr %27, align 8 - call void @foo_test3(i64 %lo24, ptr %hi25) + call void @foo.test3(i64 %lo24, ptr %hi25) store i32 2, ptr %taddr26, align 4 %28 = insertvalue %variant undef, ptr %taddr26, 0 %29 = insertvalue %variant %28, i64 ptrtoint (ptr @"ct$int" to i64), 1 @@ -318,7 +318,7 @@ entry: %lo28 = load i64, ptr %30, align 8 %31 = getelementptr inbounds { i64, ptr }, ptr %taddr27, i32 0, i32 1 %hi29 = load ptr, ptr %31, align 8 - call void @foo_test3(i64 %lo28, ptr %hi29) + call void @foo.test3(i64 %lo28, ptr %hi29) store i8 1, ptr %taddr30, align 1 %32 = insertvalue %variant undef, ptr %taddr30, 0 %33 = insertvalue %variant %32, i64 ptrtoint (ptr @"ct$bool" to i64), 1 @@ -327,6 +327,6 @@ entry: %lo32 = load i64, ptr %34, align 8 %35 = getelementptr inbounds { i64, ptr }, ptr %taddr31, i32 0, i32 1 %hi33 = load ptr, ptr %35, align 8 - call void @foo_test3(i64 %lo32, ptr %hi33) + call void @foo.test3(i64 %lo32, ptr %hi33) ret i32 0 } diff --git a/test/test_suite/variant/variant_switch.c3t b/test/test_suite/variant/variant_switch.c3t index 11b4a8f72..88e45bf41 100644 --- a/test/test_suite/variant/variant_switch.c3t +++ b/test/test_suite/variant/variant_switch.c3t @@ -34,7 +34,7 @@ fn int main() @"ct$double" = linkonce constant %.introspect { i8 4, i64 8, i64 0, i64 0, [0 x i64] zeroinitializer }, align 8 @"ct$bool" = linkonce constant %.introspect { i8 1, i64 1, i64 0, i64 0, [0 x i64] zeroinitializer }, align 8 -define void @foo_test(i64 %0, ptr %1) #0 { +define void @foo.test(i64 %0, ptr %1) #0 { entry: %z = alloca %variant, align 8 %switch = alloca i64, align 8 @@ -118,7 +118,7 @@ entry: %lo = load i64, ptr %2, align 8 %3 = getelementptr inbounds { i64, ptr }, ptr %taddr1, i32 0, i32 1 %hi = load ptr, ptr %3, align 8 - call void @foo_test(i64 %lo, ptr %hi) + call void @foo.test(i64 %lo, ptr %hi) store i32 1, ptr %taddr2, align 4 %4 = insertvalue %variant undef, ptr %taddr2, 0 %5 = insertvalue %variant %4, i64 ptrtoint (ptr @"ct$int" to i64), 1 @@ -127,7 +127,7 @@ entry: %lo4 = load i64, ptr %6, align 8 %7 = getelementptr inbounds { i64, ptr }, ptr %taddr3, i32 0, i32 1 %hi5 = load ptr, ptr %7, align 8 - call void @foo_test(i64 %lo4, ptr %hi5) + call void @foo.test(i64 %lo4, ptr %hi5) store i8 1, ptr %taddr6, align 1 %8 = insertvalue %variant undef, ptr %taddr6, 0 %9 = insertvalue %variant %8, i64 ptrtoint (ptr @"ct$bool" to i64), 1 @@ -136,6 +136,6 @@ entry: %lo8 = load i64, ptr %10, align 8 %11 = getelementptr inbounds { i64, ptr }, ptr %taddr7, i32 0, i32 1 %hi9 = load ptr, ptr %11, align 8 - call void @foo_test(i64 %lo8, ptr %hi9) + call void @foo.test(i64 %lo8, ptr %hi9) ret i32 0 } diff --git a/test/test_suite/variant/variant_test.c3t b/test/test_suite/variant/variant_test.c3t index 69b78d6ea..2a733ff88 100644 --- a/test/test_suite/variant/variant_test.c3t +++ b/test/test_suite/variant/variant_test.c3t @@ -72,7 +72,7 @@ fn void main() @"ct$p$int" = linkonce constant %.introspect { i8 19, i64 8, i64 ptrtoint (ptr @"ct$int" to i64), i64 0, [0 x i64] zeroinitializer }, align 8 @"ct$bool" = linkonce constant %.introspect { i8 1, i64 1, i64 0, i64 0, [0 x i64] zeroinitializer }, align 8 -define void @foo_test(i64 %0, ptr %1) #0 { +define void @foo.test(i64 %0, ptr %1) #0 { entry: %x = alloca %variant, align 8 %switch = alloca i64, align 8 @@ -129,7 +129,7 @@ switch.exit: ; preds = %switch.default, %sw } ; Function Attrs: nounwind -define void @foo_test_all(ptr %0, i64 %1) #0 { +define void @foo.test_all(ptr %0, i64 %1) #0 { entry: %y = alloca %"variant[]", align 8 %.anon = alloca i64, align 8 @@ -160,7 +160,7 @@ loop.body: ; preds = %loop.cond %lo = load i64, ptr %9, align 8 %10 = getelementptr inbounds { i64, ptr }, ptr %element, i32 0, i32 1 %hi = load ptr, ptr %10, align 8 - call void @foo_test(i64 %lo, ptr %hi) + call void @foo.test(i64 %lo, ptr %hi) %11 = load i64, ptr %.anon1, align 8 %add = add i64 %11, 1 store i64 %add, ptr %.anon1, align 8 @@ -171,7 +171,7 @@ loop.exit: ; preds = %loop.cond } ; Function Attrs: nounwind -define void @foo_main() #0 { +define void @foo.main() #0 { entry: %x = alloca %variant, align 8 %taddr = alloca i32, align 4 @@ -254,7 +254,7 @@ if.exit10: ; preds = %if.then9, %if.exit7 %lo = load i64, ptr %20, align 8 %21 = getelementptr inbounds { i64, ptr }, ptr %x, i32 0, i32 1 %hi = load ptr, ptr %21, align 8 - call void @foo_test(i64 %lo, ptr %hi) + call void @foo.test(i64 %lo, ptr %hi) store double 1.000000e+00, ptr %taddr11, align 8 %22 = insertvalue %variant undef, ptr %taddr11, 0 %23 = insertvalue %variant %22, i64 ptrtoint (ptr @"ct$double" to i64), 1 @@ -263,7 +263,7 @@ if.exit10: ; preds = %if.then9, %if.exit7 %lo13 = load i64, ptr %24, align 8 %25 = getelementptr inbounds { i64, ptr }, ptr %taddr12, i32 0, i32 1 %hi14 = load ptr, ptr %25, align 8 - call void @foo_test(i64 %lo13, ptr %hi14) + call void @foo.test(i64 %lo13, ptr %hi14) store i32 1, ptr %taddr15, align 4 %26 = insertvalue %variant undef, ptr %taddr15, 0 %27 = insertvalue %variant %26, i64 ptrtoint (ptr @"ct$int" to i64), 1 @@ -272,7 +272,7 @@ if.exit10: ; preds = %if.then9, %if.exit7 %lo17 = load i64, ptr %28, align 8 %29 = getelementptr inbounds { i64, ptr }, ptr %taddr16, i32 0, i32 1 %hi18 = load ptr, ptr %29, align 8 - call void @foo_test(i64 %lo17, ptr %hi18) + call void @foo.test(i64 %lo17, ptr %hi18) store i8 1, ptr %taddr19, align 1 %30 = insertvalue %variant undef, ptr %taddr19, 0 %31 = insertvalue %variant %30, i64 ptrtoint (ptr @"ct$bool" to i64), 1 @@ -281,7 +281,7 @@ if.exit10: ; preds = %if.then9, %if.exit7 %lo21 = load i64, ptr %32, align 8 %33 = getelementptr inbounds { i64, ptr }, ptr %taddr20, i32 0, i32 1 %hi22 = load ptr, ptr %33, align 8 - call void @foo_test(i64 %lo21, ptr %hi22) + call void @foo.test(i64 %lo21, ptr %hi22) call void (ptr, ...) @printf(ptr @.str.9) store ptr null, ptr %df, align 8 %34 = getelementptr inbounds [5 x %variant], ptr %varargslots, i64 0, i64 0 @@ -301,6 +301,6 @@ if.exit10: ; preds = %if.then9, %if.exit7 %43 = insertvalue %variant %42, i64 ptrtoint (ptr @"ct$p$int" to i64), 1 %44 = getelementptr inbounds [5 x %variant], ptr %varargslots, i64 0, i64 4 store %variant %43, ptr %44, align 16 - call void @foo_test_all(ptr %varargslots, i64 5) + call void @foo.test_all(ptr %varargslots, i64 5) ret void } diff --git a/test/test_suite/vector/vector_bit.c3t b/test/test_suite/vector/vector_bit.c3t index cfc851607..d9428c1f6 100644 --- a/test/test_suite/vector/vector_bit.c3t +++ b/test/test_suite/vector/vector_bit.c3t @@ -38,7 +38,7 @@ fn void main() /* #expect: vector_bit.ll -define void @vector_bit_testf() #0 { +define void @vector_bit.testf() #0 { entry: %y = alloca <4 x float>, align 16 %w = alloca <4 x i32>, align 16 @@ -60,7 +60,7 @@ entry: } ; Function Attrs: nounwind -define void @vector_bit_testi() #0 { +define void @vector_bit.testi() #0 { entry: %y = alloca <4 x i32>, align 16 %z = alloca <4 x i32>, align 16 diff --git a/test/test_suite/vector/vector_incdec.c3t b/test/test_suite/vector/vector_incdec.c3t index 0b083468c..c9bd25e1e 100644 --- a/test/test_suite/vector/vector_incdec.c3t +++ b/test/test_suite/vector/vector_incdec.c3t @@ -38,7 +38,7 @@ fn void main() /* #expect: vector_incdec.ll -define void @vector_incdec_testf() #0 { +define void @vector_incdec.testf() #0 { entry: %y = alloca <4 x float>, align 16 %z = alloca <4 x float>, align 16 @@ -113,7 +113,7 @@ entry: } ; Function Attrs: nounwind -define void @vector_incdec_testi() #0 { +define void @vector_incdec.testi() #0 { entry: %y = alloca <4 x i32>, align 16 %z = alloca <4 x i32>, align 16 @@ -182,9 +182,9 @@ entry: ret void } -define void @vector_incdec_main() #0 { +define void @vector_incdec.main() #0 { entry: - call void @vector_incdec_testf() - call void @vector_incdec_testi() + call void @vector_incdec.testf() + call void @vector_incdec.testi() ret void } diff --git a/test/test_suite/vector/vector_init.c3t b/test/test_suite/vector/vector_init.c3t index 04ab6c6e8..402fbd9bc 100644 --- a/test/test_suite/vector/vector_init.c3t +++ b/test/test_suite/vector/vector_init.c3t @@ -14,10 +14,10 @@ fn void main() /* #expect: vector_init.ll -@vector_init_baz = local_unnamed_addr global <4 x i32> , align 16 +@vector_init.baz = local_unnamed_addr global <4 x i32> , align 16 ; Function Attrs: nounwind -define void @vector_init_main() #0 { +define void @vector_init.main() #0 { entry: %foo = alloca <4 x i32>, align 16 %z = alloca i32, align 4 diff --git a/test/test_suite/vector/vector_init_regression.c3t b/test/test_suite/vector/vector_init_regression.c3t index fa2b0dff5..3459c1ad4 100644 --- a/test/test_suite/vector/vector_init_regression.c3t +++ b/test/test_suite/vector/vector_init_regression.c3t @@ -81,7 +81,7 @@ fn void main() { /* #expect: test.ll -define void @test_main() #0 { +define void @test.main() #0 { entry: %radians = alloca float, align 4 %axis = alloca <3 x float>, align 16 diff --git a/test/test_suite/vector/vector_ops2.c3t b/test/test_suite/vector/vector_ops2.c3t index e0fef8f84..f18bb3d3b 100644 --- a/test/test_suite/vector/vector_ops2.c3t +++ b/test/test_suite/vector/vector_ops2.c3t @@ -24,7 +24,7 @@ fn void testi() /* #expect: test.ll ; Function Attrs: nounwind -define void @test_testf() #0 { +define void @test.testf() #0 { entry: %y = alloca <4 x float>, align 16 %z = alloca <4 x float>, align 16 @@ -43,7 +43,7 @@ entry: br i1 %zero, label %panic, label %checkok panic: ; preds = %entry - %6 = load ptr, ptr @std_core_builtin_panic, align 8 + %6 = load ptr, ptr @std_core_builtin.panic, align 8 call void %6(ptr @.panic_msg, i64 17, ptr @.file, i64 14, ptr @.func, i64 5, i32 9) br label %checkok diff --git a/test/test_suite/vector/vector_to_array_cast.c3t b/test/test_suite/vector/vector_to_array_cast.c3t index 1d11f86f1..03e226515 100644 --- a/test/test_suite/vector/vector_to_array_cast.c3t +++ b/test/test_suite/vector/vector_to_array_cast.c3t @@ -14,10 +14,10 @@ fn void tester() /* #expect: test.ll -@test_b = local_unnamed_addr global <2 x i32> , align 8 -@test_c = local_unnamed_addr global [2 x i32] [i32 1, i32 2], align 4 +@test.b = local_unnamed_addr global <2 x i32> , align 8 +@test.c = local_unnamed_addr global [2 x i32] [i32 1, i32 2], align 4 -define void @test_tester() #0 { +define void @test.tester() #0 { entry: %x = alloca <2 x i32>, align 8 %y = alloca [2 x i32], align 4 diff --git a/test/unit/stdlib/net/inetaddr.c3 b/test/unit/stdlib/net/inetaddr.c3 index ff09d81bb..8357b848b 100644 --- a/test/unit/stdlib/net/inetaddr.c3 +++ b/test/unit/stdlib/net/inetaddr.c3 @@ -1,7 +1,7 @@ -module inetaddrtest; +module inetaddrtest @test; import std::net; -fn void test_ipv4() @test +fn void test_ipv4() { InetAddress foo = { .ipv4 = { 127, 0, 0, 0 } }; assert(foo.ip4.val == 2130706432); @@ -9,13 +9,13 @@ fn void test_ipv4() @test } -fn void! test_ipv4_to_string() @test +fn void! test_ipv4_to_string() { InetAddress a = net::ipv4_from_str("127.0.0.1")?; assert(a.to_string()? == "127.0.0.1"); } -fn void! test_ipv6_to_string() @test +fn void! test_ipv6_to_string() { InetAddress a = net::ipv6_from_str("2001:db8::2:1")?; a.to_string()?; @@ -28,7 +28,7 @@ fn void! test_ipv6_to_string() @test assert(net::ipv6_from_str("::").to_string()? == "0000:0000:0000:0000:0000:0000:0000:0000"); } -fn void! test_ipv4_parse() @test +fn void! test_ipv4_parse() { InetAddress a = net::ipv4_from_str("127.0.0.1")?; assert(a.ipv4.a == 127 && a.ipv4.b == 0 && a.ipv4.c == 0 && a.ipv4.d == 1); @@ -41,7 +41,7 @@ fn void! test_ipv4_parse() @test assert(catch(net::ipv4_from_str("256.1.1.1"))); } -fn void test_ipv6() @test +fn void test_ipv6() { InetAddress foo = { .ipv6 = { 0x2001, 0x4860, 0x4860, 0, 0, 0, 0, 0x8888 } }; assert(foo.ip6.val == 42541956123769884636017138956568135816);