mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-05 11:51:04 +01:00
Reduce the size of formatted SemIR. (#4534)
- Do not include entities imported from files that we are not dumping. - Do not include constants and import_refs that are not referenced by something that we are including in the formatted output. --------- Co-authored-by: Jon Ross-Perkins <jperkins@google.com> Co-authored-by: Carbon Infra Bot <carbon-external-infra@google.com>
This commit is contained in:
co-authored by
Jon Ross-Perkins
Carbon Infra Bot
parent
3c18a6c477
commit
4ee65ef58a
@@ -18,7 +18,6 @@ fn G() {
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: constants {
|
||||
// CHECK:STDOUT: %Int32.type: type = fn_type @Int32 [template]
|
||||
// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template]
|
||||
// CHECK:STDOUT: %Int32: %Int32.type = struct_value () [template]
|
||||
// CHECK:STDOUT: %tuple.type.1: type = tuple_type (type, type, type) [template]
|
||||
// CHECK:STDOUT: %tuple.type.2: type = tuple_type (i32, i32, i32) [template]
|
||||
@@ -28,8 +27,6 @@ fn G() {
|
||||
// CHECK:STDOUT: %G: %G.type = struct_value () [template]
|
||||
// CHECK:STDOUT: %.1: i32 = int_value 2 [template]
|
||||
// CHECK:STDOUT: %.2: type = array_type %.1, %tuple.type.2 [template]
|
||||
// CHECK:STDOUT: %.3: type = ptr_type %tuple.type.2 [template]
|
||||
// CHECK:STDOUT: %.4: type = ptr_type %.2 [template]
|
||||
// CHECK:STDOUT: %tuple.type.3: type = tuple_type (%tuple.type.2, %tuple.type.2) [template]
|
||||
// CHECK:STDOUT: %.5: i32 = int_value 0 [template]
|
||||
// CHECK:STDOUT: %.6: i32 = int_value 1 [template]
|
||||
@@ -41,7 +38,6 @@ fn G() {
|
||||
// CHECK:STDOUT: import Core//prelude
|
||||
// CHECK:STDOUT: import Core//prelude/...
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %import_ref: %Int32.type = import_ref Core//prelude/types, inst+15, loaded [template = constants.%Int32]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: file {
|
||||
@@ -72,8 +68,6 @@ fn G() {
|
||||
// CHECK:STDOUT: %G.decl: %G.type = fn_decl @G [template = constants.%G] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Int32() -> type = "int.make_type_32";
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @F() -> %tuple.type.2;
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @G() {
|
||||
|
||||
@@ -18,20 +18,17 @@ fn G() {
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: constants {
|
||||
// CHECK:STDOUT: %G.type: type = fn_type @G [template]
|
||||
// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template]
|
||||
// CHECK:STDOUT: %G: %G.type = struct_value () [template]
|
||||
// CHECK:STDOUT: %Int32.type: type = fn_type @Int32 [template]
|
||||
// CHECK:STDOUT: %Int32: %Int32.type = struct_value () [template]
|
||||
// CHECK:STDOUT: %.1: i32 = int_value 3 [template]
|
||||
// CHECK:STDOUT: %.2: type = array_type %.1, i32 [template]
|
||||
// CHECK:STDOUT: %.3: type = ptr_type %.2 [template]
|
||||
// CHECK:STDOUT: %.4: i32 = int_value 1 [template]
|
||||
// CHECK:STDOUT: %.5: i32 = int_value 2 [template]
|
||||
// CHECK:STDOUT: %tuple.type.1: type = tuple_type (i32, i32, i32) [template]
|
||||
// CHECK:STDOUT: %.6: i32 = int_value 0 [template]
|
||||
// CHECK:STDOUT: %array: %.2 = tuple_value (%.4, %.5, %.1) [template]
|
||||
// CHECK:STDOUT: %tuple.type.2: type = tuple_type (type, type, type) [template]
|
||||
// CHECK:STDOUT: %.7: type = ptr_type %tuple.type.1 [template]
|
||||
// CHECK:STDOUT: %tuple: %tuple.type.1 = tuple_value (%.4, %.5, %.1) [template]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -41,7 +38,6 @@ fn G() {
|
||||
// CHECK:STDOUT: import Core//prelude
|
||||
// CHECK:STDOUT: import Core//prelude/...
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %import_ref: %Int32.type = import_ref Core//prelude/types, inst+15, loaded [template = constants.%Int32]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: file {
|
||||
@@ -107,5 +103,3 @@ fn G() {
|
||||
// CHECK:STDOUT: return
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Int32() -> type = "int.make_type_32";
|
||||
// CHECK:STDOUT:
|
||||
|
||||
@@ -18,7 +18,6 @@ fn Run() {
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: constants {
|
||||
// CHECK:STDOUT: %Int32.type: type = fn_type @Int32 [template]
|
||||
// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template]
|
||||
// CHECK:STDOUT: %Int32: %Int32.type = struct_value () [template]
|
||||
// CHECK:STDOUT: %tuple.type.1: type = tuple_type (type) [template]
|
||||
// CHECK:STDOUT: %tuple.type.2: type = tuple_type (i32) [template]
|
||||
@@ -30,7 +29,6 @@ fn Run() {
|
||||
// CHECK:STDOUT: %Run: %Run.type = struct_value () [template]
|
||||
// CHECK:STDOUT: %.2: i32 = int_value 1 [template]
|
||||
// CHECK:STDOUT: %.3: type = array_type %.2, i32 [template]
|
||||
// CHECK:STDOUT: %.4: type = ptr_type %.3 [template]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: imports {
|
||||
@@ -39,7 +37,6 @@ fn Run() {
|
||||
// CHECK:STDOUT: import Core//prelude
|
||||
// CHECK:STDOUT: import Core//prelude/...
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %import_ref: %Int32.type = import_ref Core//prelude/types, inst+15, loaded [template = constants.%Int32]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: file {
|
||||
@@ -64,8 +61,6 @@ fn Run() {
|
||||
// CHECK:STDOUT: %Run.decl: %Run.type = fn_decl @Run [template = constants.%Run] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Int32() -> type = "int.make_type_32";
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @F() -> %tuple.type.2 {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: %.loc11_28: i32 = int_value 0 [template = constants.%.1]
|
||||
|
||||
@@ -15,17 +15,14 @@ var b: [i32; 3] = a;
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: constants {
|
||||
// CHECK:STDOUT: %Int32.type: type = fn_type @Int32 [template]
|
||||
// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template]
|
||||
// CHECK:STDOUT: %Int32: %Int32.type = struct_value () [template]
|
||||
// CHECK:STDOUT: %tuple.type.1: type = tuple_type (type, type, type) [template]
|
||||
// CHECK:STDOUT: %tuple.type.2: type = tuple_type (i32, i32, i32) [template]
|
||||
// CHECK:STDOUT: %.1: type = ptr_type %tuple.type.2 [template]
|
||||
// CHECK:STDOUT: %.2: i32 = int_value 1 [template]
|
||||
// CHECK:STDOUT: %.3: i32 = int_value 2 [template]
|
||||
// CHECK:STDOUT: %.4: i32 = int_value 3 [template]
|
||||
// CHECK:STDOUT: %tuple: %tuple.type.2 = tuple_value (%.2, %.3, %.4) [template]
|
||||
// CHECK:STDOUT: %.5: type = array_type %.4, i32 [template]
|
||||
// CHECK:STDOUT: %.6: type = ptr_type %.5 [template]
|
||||
// CHECK:STDOUT: %.7: i32 = int_value 0 [template]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -35,7 +32,6 @@ var b: [i32; 3] = a;
|
||||
// CHECK:STDOUT: import Core//prelude
|
||||
// CHECK:STDOUT: import Core//prelude/...
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %import_ref: %Int32.type = import_ref Core//prelude/types, inst+15, loaded [template = constants.%Int32]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: file {
|
||||
@@ -67,8 +63,6 @@ var b: [i32; 3] = a;
|
||||
// CHECK:STDOUT: %b: ref %.5 = bind_name b, %b.var
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Int32() -> type = "int.make_type_32";
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @__global_init() {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: %.loc11_27: i32 = int_value 1 [template = constants.%.2]
|
||||
|
||||
-9
@@ -20,7 +20,6 @@ var c: [(); 5] = ((), (), (), (), (),);
|
||||
// CHECK:STDOUT: %Int32: %Int32.type = struct_value () [template]
|
||||
// CHECK:STDOUT: %.1: i32 = int_value 1 [template]
|
||||
// CHECK:STDOUT: %.2: type = array_type %.1, i32 [template]
|
||||
// CHECK:STDOUT: %.3: type = ptr_type %.2 [template]
|
||||
// CHECK:STDOUT: %tuple.type.1: type = tuple_type (i32) [template]
|
||||
// CHECK:STDOUT: %.4: i32 = int_value 0 [template]
|
||||
// CHECK:STDOUT: %array.1: %.2 = tuple_value (%.1) [template]
|
||||
@@ -29,14 +28,12 @@ var c: [(); 5] = ((), (), (), (), (),);
|
||||
// CHECK:STDOUT: %Float: %Float.type = struct_value () [template]
|
||||
// CHECK:STDOUT: %.6: i32 = int_value 2 [template]
|
||||
// CHECK:STDOUT: %.7: type = array_type %.6, f64 [template]
|
||||
// CHECK:STDOUT: %.8: type = ptr_type %.7 [template]
|
||||
// CHECK:STDOUT: %.9: f64 = float_literal 11.100000000000001 [template]
|
||||
// CHECK:STDOUT: %.10: f64 = float_literal 2.2000000000000002 [template]
|
||||
// CHECK:STDOUT: %tuple.type.2: type = tuple_type (f64, f64) [template]
|
||||
// CHECK:STDOUT: %array.2: %.7 = tuple_value (%.9, %.10) [template]
|
||||
// CHECK:STDOUT: %.11: i32 = int_value 5 [template]
|
||||
// CHECK:STDOUT: %.12: type = array_type %.11, %empty_tuple.type [template]
|
||||
// CHECK:STDOUT: %.13: type = ptr_type %.12 [template]
|
||||
// CHECK:STDOUT: %tuple.type.3: type = tuple_type (%empty_tuple.type, %empty_tuple.type, %empty_tuple.type, %empty_tuple.type, %empty_tuple.type) [template]
|
||||
// CHECK:STDOUT: %empty_tuple: %empty_tuple.type = tuple_value () [template]
|
||||
// CHECK:STDOUT: %.14: i32 = int_value 3 [template]
|
||||
@@ -51,8 +48,6 @@ var c: [(); 5] = ((), (), (), (), (),);
|
||||
// CHECK:STDOUT: import Core//prelude
|
||||
// CHECK:STDOUT: import Core//prelude/...
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %import_ref.1: %Int32.type = import_ref Core//prelude/types, inst+15, loaded [template = constants.%Int32]
|
||||
// CHECK:STDOUT: %import_ref.2: %Float.type = import_ref Core//prelude/types, inst+60, loaded [template = constants.%Float]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: file {
|
||||
@@ -86,10 +81,6 @@ var c: [(); 5] = ((), (), (), (), (),);
|
||||
// CHECK:STDOUT: %c: ref %.12 = bind_name c, %c.var
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Int32() -> type = "int.make_type_32";
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Float(%size.param_patt: Core.IntLiteral) -> type = "float.make_type";
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @__global_init() {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: %.loc11_20: i32 = int_value 1 [template = constants.%.1]
|
||||
|
||||
@@ -17,7 +17,6 @@ let b: [i32; 3]* = &a;
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: constants {
|
||||
// CHECK:STDOUT: %Int32.type: type = fn_type @Int32 [template]
|
||||
// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template]
|
||||
// CHECK:STDOUT: %Int32: %Int32.type = struct_value () [template]
|
||||
// CHECK:STDOUT: %Add.type: type = fn_type @Add [template]
|
||||
// CHECK:STDOUT: %Add: %Add.type = struct_value () [template]
|
||||
@@ -37,7 +36,6 @@ let b: [i32; 3]* = &a;
|
||||
// CHECK:STDOUT: import Core//prelude
|
||||
// CHECK:STDOUT: import Core//prelude/...
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %import_ref: %Int32.type = import_ref Core//prelude/types, inst+15, loaded [template = constants.%Int32]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: file {
|
||||
@@ -90,8 +88,6 @@ let b: [i32; 3]* = &a;
|
||||
// CHECK:STDOUT: %.loc14_16: type = ptr_type %.4 [template = constants.%.5]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Int32() -> type = "int.make_type_32";
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Add(%a.param_patt: i32, %b.param_patt: i32) -> i32 = "int.sadd";
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @__global_init() {
|
||||
|
||||
@@ -19,7 +19,6 @@ var a: [i32; Negate(1)];
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: constants {
|
||||
// CHECK:STDOUT: %Int32.type: type = fn_type @Int32 [template]
|
||||
// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template]
|
||||
// CHECK:STDOUT: %Int32: %Int32.type = struct_value () [template]
|
||||
// CHECK:STDOUT: %Negate.type: type = fn_type @Negate [template]
|
||||
// CHECK:STDOUT: %Negate: %Negate.type = struct_value () [template]
|
||||
@@ -33,7 +32,6 @@ var a: [i32; Negate(1)];
|
||||
// CHECK:STDOUT: import Core//prelude
|
||||
// CHECK:STDOUT: import Core//prelude/...
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %import_ref: %Int32.type = import_ref Core//prelude/types, inst+15, loaded [template = constants.%Int32]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: file {
|
||||
@@ -71,7 +69,5 @@ var a: [i32; Negate(1)];
|
||||
// CHECK:STDOUT: %a: ref <error> = bind_name a, %a.var
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Int32() -> type = "int.make_type_32";
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Negate(%n.param_patt: i32) -> i32 = "int.snegate";
|
||||
// CHECK:STDOUT:
|
||||
|
||||
@@ -33,26 +33,8 @@ var b: [1; 39999999999999999993];
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: constants {
|
||||
// CHECK:STDOUT: %Int32.type: type = fn_type @Int32 [template]
|
||||
// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template]
|
||||
// CHECK:STDOUT: %Int32: %Int32.type = struct_value () [template]
|
||||
// CHECK:STDOUT: %.1: i32 = int_value 1 [template]
|
||||
// CHECK:STDOUT: %ImplicitAs.type.1: type = generic_interface_type @ImplicitAs [template]
|
||||
// CHECK:STDOUT: %ImplicitAs: %ImplicitAs.type.1 = struct_value () [template]
|
||||
// CHECK:STDOUT: %Dest: type = bind_symbolic_name Dest, 0 [symbolic]
|
||||
// CHECK:STDOUT: %ImplicitAs.type.2: type = facet_type <@ImplicitAs, @ImplicitAs(%Dest)> [symbolic]
|
||||
// CHECK:STDOUT: %Self.1: @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2) = bind_symbolic_name Self, 1 [symbolic]
|
||||
// CHECK:STDOUT: %Dest.patt: type = symbolic_binding_pattern Dest, 0 [symbolic]
|
||||
// CHECK:STDOUT: %Self.2: %ImplicitAs.type.2 = bind_symbolic_name Self, 1 [symbolic]
|
||||
// CHECK:STDOUT: %Convert.type.1: type = fn_type @Convert, @ImplicitAs(%Dest) [symbolic]
|
||||
// CHECK:STDOUT: %Convert.1: %Convert.type.1 = struct_value () [symbolic]
|
||||
// CHECK:STDOUT: %.2: type = assoc_entity_type %ImplicitAs.type.2, %Convert.type.1 [symbolic]
|
||||
// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, imports.%import_ref.6 [symbolic]
|
||||
// CHECK:STDOUT: %ImplicitAs.type.3: type = facet_type <@ImplicitAs, @ImplicitAs(type)> [template]
|
||||
// CHECK:STDOUT: %Convert.type.2: type = fn_type @Convert, @ImplicitAs(type) [template]
|
||||
// CHECK:STDOUT: %Convert.2: %Convert.type.2 = struct_value () [template]
|
||||
// CHECK:STDOUT: %.4: type = assoc_entity_type %ImplicitAs.type.3, %Convert.type.2 [template]
|
||||
// CHECK:STDOUT: %.5: %.4 = assoc_entity element0, imports.%import_ref.6 [template]
|
||||
// CHECK:STDOUT: %.6: %.2 = assoc_entity element0, imports.%import_ref.7 [symbolic]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: imports {
|
||||
@@ -62,13 +44,6 @@ var b: [1; 39999999999999999993];
|
||||
// CHECK:STDOUT: import Core//prelude
|
||||
// CHECK:STDOUT: import Core//prelude/...
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %import_ref.1: %Int32.type = import_ref Core//prelude/types, inst+15, loaded [template = constants.%Int32]
|
||||
// CHECK:STDOUT: %import_ref.2: %ImplicitAs.type.1 = import_ref Core//prelude/operators/as, inst+48, loaded [template = constants.%ImplicitAs]
|
||||
// CHECK:STDOUT: %import_ref.3 = import_ref Core//prelude/operators/as, inst+54, unloaded
|
||||
// CHECK:STDOUT: %import_ref.4: @ImplicitAs.%.1 (%.2) = import_ref Core//prelude/operators/as, inst+76, loaded [symbolic = @ImplicitAs.%.2 (constants.%.6)]
|
||||
// CHECK:STDOUT: %import_ref.5 = import_ref Core//prelude/operators/as, inst+69, unloaded
|
||||
// CHECK:STDOUT: %import_ref.6 = import_ref Core//prelude/operators/as, inst+69, unloaded
|
||||
// CHECK:STDOUT: %import_ref.7 = import_ref Core//prelude/operators/as, inst+69, unloaded
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: file {
|
||||
@@ -91,67 +66,3 @@ var b: [1; 39999999999999999993];
|
||||
// CHECK:STDOUT: %b: ref <error> = bind_name b, %b.var
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: generic interface @ImplicitAs(constants.%Dest: type) {
|
||||
// CHECK:STDOUT: %Dest: type = bind_symbolic_name Dest, 0 [symbolic = %Dest (constants.%Dest)]
|
||||
// CHECK:STDOUT: %Dest.patt: type = symbolic_binding_pattern Dest, 0 [symbolic = %Dest.patt (constants.%Dest.patt)]
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !definition:
|
||||
// CHECK:STDOUT: %ImplicitAs.type: type = facet_type <@ImplicitAs, @ImplicitAs(%Dest)> [symbolic = %ImplicitAs.type (constants.%ImplicitAs.type.2)]
|
||||
// CHECK:STDOUT: %Self: %ImplicitAs.type.2 = bind_symbolic_name Self, 1 [symbolic = %Self (constants.%Self.2)]
|
||||
// CHECK:STDOUT: %Convert.type: type = fn_type @Convert, @ImplicitAs(%Dest) [symbolic = %Convert.type (constants.%Convert.type.1)]
|
||||
// CHECK:STDOUT: %Convert: @ImplicitAs.%Convert.type (%Convert.type.1) = struct_value () [symbolic = %Convert (constants.%Convert.1)]
|
||||
// CHECK:STDOUT: %.1: type = assoc_entity_type @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2), @ImplicitAs.%Convert.type (%Convert.type.1) [symbolic = %.1 (constants.%.2)]
|
||||
// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity element0, imports.%import_ref.6 [symbolic = %.2 (constants.%.3)]
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: interface {
|
||||
// CHECK:STDOUT: !members:
|
||||
// CHECK:STDOUT: .Self = imports.%import_ref.3
|
||||
// CHECK:STDOUT: .Convert = imports.%import_ref.4
|
||||
// CHECK:STDOUT: witness = (imports.%import_ref.5)
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Int32() -> type = "int.make_type_32";
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: generic fn @Convert(constants.%Dest: type, constants.%Self.1: @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2)) {
|
||||
// CHECK:STDOUT: %Dest: type = bind_symbolic_name Dest, 0 [symbolic = %Dest (constants.%Dest)]
|
||||
// CHECK:STDOUT: %ImplicitAs.type: type = facet_type <@ImplicitAs, @ImplicitAs(%Dest)> [symbolic = %ImplicitAs.type (constants.%ImplicitAs.type.2)]
|
||||
// CHECK:STDOUT: %Self: %ImplicitAs.type.2 = bind_symbolic_name Self, 1 [symbolic = %Self (constants.%Self.2)]
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn[%self.param_patt: @Convert.%Self (%Self.2)]() -> @Convert.%Dest (%Dest);
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @ImplicitAs(constants.%Dest) {
|
||||
// CHECK:STDOUT: %Dest => constants.%Dest
|
||||
// CHECK:STDOUT: %Dest.patt => constants.%Dest
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @ImplicitAs(@ImplicitAs.%Dest) {
|
||||
// CHECK:STDOUT: %Dest => constants.%Dest
|
||||
// CHECK:STDOUT: %Dest.patt => constants.%Dest
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @ImplicitAs(@Convert.%Dest) {
|
||||
// CHECK:STDOUT: %Dest => constants.%Dest
|
||||
// CHECK:STDOUT: %Dest.patt => constants.%Dest
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @Convert(constants.%Dest, constants.%Self.1) {
|
||||
// CHECK:STDOUT: %Dest => constants.%Dest
|
||||
// CHECK:STDOUT: %ImplicitAs.type => constants.%ImplicitAs.type.2
|
||||
// CHECK:STDOUT: %Self => constants.%Self.1
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @ImplicitAs(type) {
|
||||
// CHECK:STDOUT: %Dest => type
|
||||
// CHECK:STDOUT: %Dest.patt => type
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !definition:
|
||||
// CHECK:STDOUT: %ImplicitAs.type => constants.%ImplicitAs.type.3
|
||||
// CHECK:STDOUT: %Self => constants.%Self.2
|
||||
// CHECK:STDOUT: %Convert.type => constants.%Convert.type.2
|
||||
// CHECK:STDOUT: %Convert => constants.%Convert.2
|
||||
// CHECK:STDOUT: %.1 => constants.%.4
|
||||
// CHECK:STDOUT: %.2 => constants.%.5
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
|
||||
@@ -20,24 +20,6 @@ var a: [1; 1];
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: constants {
|
||||
// CHECK:STDOUT: %.1: i32 = int_value 1 [template]
|
||||
// CHECK:STDOUT: %ImplicitAs.type.1: type = generic_interface_type @ImplicitAs [template]
|
||||
// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template]
|
||||
// CHECK:STDOUT: %ImplicitAs: %ImplicitAs.type.1 = struct_value () [template]
|
||||
// CHECK:STDOUT: %Dest: type = bind_symbolic_name Dest, 0 [symbolic]
|
||||
// CHECK:STDOUT: %ImplicitAs.type.2: type = facet_type <@ImplicitAs, @ImplicitAs(%Dest)> [symbolic]
|
||||
// CHECK:STDOUT: %Self.1: @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2) = bind_symbolic_name Self, 1 [symbolic]
|
||||
// CHECK:STDOUT: %Dest.patt: type = symbolic_binding_pattern Dest, 0 [symbolic]
|
||||
// CHECK:STDOUT: %Self.2: %ImplicitAs.type.2 = bind_symbolic_name Self, 1 [symbolic]
|
||||
// CHECK:STDOUT: %Convert.type.1: type = fn_type @Convert, @ImplicitAs(%Dest) [symbolic]
|
||||
// CHECK:STDOUT: %Convert.1: %Convert.type.1 = struct_value () [symbolic]
|
||||
// CHECK:STDOUT: %.2: type = assoc_entity_type %ImplicitAs.type.2, %Convert.type.1 [symbolic]
|
||||
// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, imports.%import_ref.5 [symbolic]
|
||||
// CHECK:STDOUT: %ImplicitAs.type.3: type = facet_type <@ImplicitAs, @ImplicitAs(type)> [template]
|
||||
// CHECK:STDOUT: %Convert.type.2: type = fn_type @Convert, @ImplicitAs(type) [template]
|
||||
// CHECK:STDOUT: %Convert.2: %Convert.type.2 = struct_value () [template]
|
||||
// CHECK:STDOUT: %.4: type = assoc_entity_type %ImplicitAs.type.3, %Convert.type.2 [template]
|
||||
// CHECK:STDOUT: %.5: %.4 = assoc_entity element0, imports.%import_ref.5 [template]
|
||||
// CHECK:STDOUT: %.6: %.2 = assoc_entity element0, imports.%import_ref.6 [symbolic]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: imports {
|
||||
@@ -46,12 +28,6 @@ var a: [1; 1];
|
||||
// CHECK:STDOUT: import Core//prelude
|
||||
// CHECK:STDOUT: import Core//prelude/...
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %import_ref.1: %ImplicitAs.type.1 = import_ref Core//prelude/operators/as, inst+48, loaded [template = constants.%ImplicitAs]
|
||||
// CHECK:STDOUT: %import_ref.2 = import_ref Core//prelude/operators/as, inst+54, unloaded
|
||||
// CHECK:STDOUT: %import_ref.3: @ImplicitAs.%.1 (%.2) = import_ref Core//prelude/operators/as, inst+76, loaded [symbolic = @ImplicitAs.%.2 (constants.%.6)]
|
||||
// CHECK:STDOUT: %import_ref.4 = import_ref Core//prelude/operators/as, inst+69, unloaded
|
||||
// CHECK:STDOUT: %import_ref.5 = import_ref Core//prelude/operators/as, inst+69, unloaded
|
||||
// CHECK:STDOUT: %import_ref.6 = import_ref Core//prelude/operators/as, inst+69, unloaded
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: file {
|
||||
@@ -68,65 +44,3 @@ var a: [1; 1];
|
||||
// CHECK:STDOUT: %a: ref <error> = bind_name a, %a.var
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: generic interface @ImplicitAs(constants.%Dest: type) {
|
||||
// CHECK:STDOUT: %Dest: type = bind_symbolic_name Dest, 0 [symbolic = %Dest (constants.%Dest)]
|
||||
// CHECK:STDOUT: %Dest.patt: type = symbolic_binding_pattern Dest, 0 [symbolic = %Dest.patt (constants.%Dest.patt)]
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !definition:
|
||||
// CHECK:STDOUT: %ImplicitAs.type: type = facet_type <@ImplicitAs, @ImplicitAs(%Dest)> [symbolic = %ImplicitAs.type (constants.%ImplicitAs.type.2)]
|
||||
// CHECK:STDOUT: %Self: %ImplicitAs.type.2 = bind_symbolic_name Self, 1 [symbolic = %Self (constants.%Self.2)]
|
||||
// CHECK:STDOUT: %Convert.type: type = fn_type @Convert, @ImplicitAs(%Dest) [symbolic = %Convert.type (constants.%Convert.type.1)]
|
||||
// CHECK:STDOUT: %Convert: @ImplicitAs.%Convert.type (%Convert.type.1) = struct_value () [symbolic = %Convert (constants.%Convert.1)]
|
||||
// CHECK:STDOUT: %.1: type = assoc_entity_type @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2), @ImplicitAs.%Convert.type (%Convert.type.1) [symbolic = %.1 (constants.%.2)]
|
||||
// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity element0, imports.%import_ref.5 [symbolic = %.2 (constants.%.3)]
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: interface {
|
||||
// CHECK:STDOUT: !members:
|
||||
// CHECK:STDOUT: .Self = imports.%import_ref.2
|
||||
// CHECK:STDOUT: .Convert = imports.%import_ref.3
|
||||
// CHECK:STDOUT: witness = (imports.%import_ref.4)
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: generic fn @Convert(constants.%Dest: type, constants.%Self.1: @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2)) {
|
||||
// CHECK:STDOUT: %Dest: type = bind_symbolic_name Dest, 0 [symbolic = %Dest (constants.%Dest)]
|
||||
// CHECK:STDOUT: %ImplicitAs.type: type = facet_type <@ImplicitAs, @ImplicitAs(%Dest)> [symbolic = %ImplicitAs.type (constants.%ImplicitAs.type.2)]
|
||||
// CHECK:STDOUT: %Self: %ImplicitAs.type.2 = bind_symbolic_name Self, 1 [symbolic = %Self (constants.%Self.2)]
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn[%self.param_patt: @Convert.%Self (%Self.2)]() -> @Convert.%Dest (%Dest);
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @ImplicitAs(constants.%Dest) {
|
||||
// CHECK:STDOUT: %Dest => constants.%Dest
|
||||
// CHECK:STDOUT: %Dest.patt => constants.%Dest
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @ImplicitAs(@ImplicitAs.%Dest) {
|
||||
// CHECK:STDOUT: %Dest => constants.%Dest
|
||||
// CHECK:STDOUT: %Dest.patt => constants.%Dest
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @ImplicitAs(@Convert.%Dest) {
|
||||
// CHECK:STDOUT: %Dest => constants.%Dest
|
||||
// CHECK:STDOUT: %Dest.patt => constants.%Dest
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @Convert(constants.%Dest, constants.%Self.1) {
|
||||
// CHECK:STDOUT: %Dest => constants.%Dest
|
||||
// CHECK:STDOUT: %ImplicitAs.type => constants.%ImplicitAs.type.2
|
||||
// CHECK:STDOUT: %Self => constants.%Self.1
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @ImplicitAs(type) {
|
||||
// CHECK:STDOUT: %Dest => type
|
||||
// CHECK:STDOUT: %Dest.patt => type
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !definition:
|
||||
// CHECK:STDOUT: %ImplicitAs.type => constants.%ImplicitAs.type.3
|
||||
// CHECK:STDOUT: %Self => constants.%Self.2
|
||||
// CHECK:STDOUT: %Convert.type => constants.%Convert.type.2
|
||||
// CHECK:STDOUT: %Convert => constants.%Convert.2
|
||||
// CHECK:STDOUT: %.1 => constants.%.4
|
||||
// CHECK:STDOUT: %.2 => constants.%.5
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
|
||||
@@ -17,11 +17,9 @@ var a: [i32; 1] = (1, 2, 3);
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: constants {
|
||||
// CHECK:STDOUT: %Int32.type: type = fn_type @Int32 [template]
|
||||
// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template]
|
||||
// CHECK:STDOUT: %Int32: %Int32.type = struct_value () [template]
|
||||
// CHECK:STDOUT: %.1: i32 = int_value 1 [template]
|
||||
// CHECK:STDOUT: %.2: type = array_type %.1, i32 [template]
|
||||
// CHECK:STDOUT: %.3: type = ptr_type %.2 [template]
|
||||
// CHECK:STDOUT: %.4: i32 = int_value 2 [template]
|
||||
// CHECK:STDOUT: %.5: i32 = int_value 3 [template]
|
||||
// CHECK:STDOUT: %tuple.type: type = tuple_type (i32, i32, i32) [template]
|
||||
@@ -33,7 +31,6 @@ var a: [i32; 1] = (1, 2, 3);
|
||||
// CHECK:STDOUT: import Core//prelude
|
||||
// CHECK:STDOUT: import Core//prelude/...
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %import_ref: %Int32.type = import_ref Core//prelude/types, inst+15, loaded [template = constants.%Int32]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: file {
|
||||
@@ -51,8 +48,6 @@ var a: [i32; 1] = (1, 2, 3);
|
||||
// CHECK:STDOUT: %a: ref %.2 = bind_name a, %a.var
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Int32() -> type = "int.make_type_32";
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @__global_init() {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: %.loc14_20: i32 = int_value 1 [template = constants.%.1]
|
||||
|
||||
@@ -18,11 +18,9 @@ var b: i32 = a[{.index = 3}.index];
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: constants {
|
||||
// CHECK:STDOUT: %Int32.type: type = fn_type @Int32 [template]
|
||||
// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template]
|
||||
// CHECK:STDOUT: %Int32: %Int32.type = struct_value () [template]
|
||||
// CHECK:STDOUT: %.1: i32 = int_value 3 [template]
|
||||
// CHECK:STDOUT: %.2: type = array_type %.1, i32 [template]
|
||||
// CHECK:STDOUT: %.3: type = ptr_type %.2 [template]
|
||||
// CHECK:STDOUT: %.4: i32 = int_value 1 [template]
|
||||
// CHECK:STDOUT: %.5: i32 = int_value 2 [template]
|
||||
// CHECK:STDOUT: %tuple.type: type = tuple_type (i32, i32, i32) [template]
|
||||
@@ -38,7 +36,6 @@ var b: i32 = a[{.index = 3}.index];
|
||||
// CHECK:STDOUT: import Core//prelude
|
||||
// CHECK:STDOUT: import Core//prelude/...
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %import_ref: %Int32.type = import_ref Core//prelude/types, inst+15, loaded [template = constants.%Int32]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: file {
|
||||
@@ -62,8 +59,6 @@ var b: i32 = a[{.index = 3}.index];
|
||||
// CHECK:STDOUT: %b: ref i32 = bind_name b, %b.var
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Int32() -> type = "int.make_type_32";
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @__global_init() {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: %.loc11_20: i32 = int_value 1 [template = constants.%.4]
|
||||
|
||||
@@ -43,41 +43,18 @@ var d: [i32; 3] = t2;
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: constants {
|
||||
// CHECK:STDOUT: %Int32.type: type = fn_type @Int32 [template]
|
||||
// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template]
|
||||
// CHECK:STDOUT: %Int32: %Int32.type = struct_value () [template]
|
||||
// CHECK:STDOUT: %.1: i32 = int_value 3 [template]
|
||||
// CHECK:STDOUT: %.2: type = array_type %.1, i32 [template]
|
||||
// CHECK:STDOUT: %.3: type = ptr_type %.2 [template]
|
||||
// CHECK:STDOUT: %.4: i32 = int_value 1 [template]
|
||||
// CHECK:STDOUT: %.5: type = ptr_type String [template]
|
||||
// CHECK:STDOUT: %.6: String = string_literal "Hello" [template]
|
||||
// CHECK:STDOUT: %.7: String = string_literal "World" [template]
|
||||
// CHECK:STDOUT: %tuple.type.1: type = tuple_type (i32, String, String) [template]
|
||||
// CHECK:STDOUT: %.8: i32 = int_value 0 [template]
|
||||
// CHECK:STDOUT: %ImplicitAs.type.1: type = generic_interface_type @ImplicitAs [template]
|
||||
// CHECK:STDOUT: %ImplicitAs: %ImplicitAs.type.1 = struct_value () [template]
|
||||
// CHECK:STDOUT: %Dest: type = bind_symbolic_name Dest, 0 [symbolic]
|
||||
// CHECK:STDOUT: %ImplicitAs.type.2: type = facet_type <@ImplicitAs, @ImplicitAs(%Dest)> [symbolic]
|
||||
// CHECK:STDOUT: %Self.1: @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2) = bind_symbolic_name Self, 1 [symbolic]
|
||||
// CHECK:STDOUT: %Dest.patt: type = symbolic_binding_pattern Dest, 0 [symbolic]
|
||||
// CHECK:STDOUT: %Self.2: %ImplicitAs.type.2 = bind_symbolic_name Self, 1 [symbolic]
|
||||
// CHECK:STDOUT: %Convert.type.1: type = fn_type @Convert, @ImplicitAs(%Dest) [symbolic]
|
||||
// CHECK:STDOUT: %Convert.1: %Convert.type.1 = struct_value () [symbolic]
|
||||
// CHECK:STDOUT: %.9: type = assoc_entity_type %ImplicitAs.type.2, %Convert.type.1 [symbolic]
|
||||
// CHECK:STDOUT: %.10: %.9 = assoc_entity element0, imports.%import_ref.6 [symbolic]
|
||||
// CHECK:STDOUT: %ImplicitAs.type.3: type = facet_type <@ImplicitAs, @ImplicitAs(i32)> [template]
|
||||
// CHECK:STDOUT: %Convert.type.2: type = fn_type @Convert, @ImplicitAs(i32) [template]
|
||||
// CHECK:STDOUT: %Convert.2: %Convert.type.2 = struct_value () [template]
|
||||
// CHECK:STDOUT: %.11: type = assoc_entity_type %ImplicitAs.type.3, %Convert.type.2 [template]
|
||||
// CHECK:STDOUT: %.12: %.11 = assoc_entity element0, imports.%import_ref.6 [template]
|
||||
// CHECK:STDOUT: %.13: %.9 = assoc_entity element0, imports.%import_ref.7 [symbolic]
|
||||
// CHECK:STDOUT: %tuple.type.2: type = tuple_type (type, type, type) [template]
|
||||
// CHECK:STDOUT: %tuple.type.3: type = tuple_type (i32, %.5, %.5) [template]
|
||||
// CHECK:STDOUT: %.14: type = ptr_type %tuple.type.3 [template]
|
||||
// CHECK:STDOUT: %.15: i32 = int_value 2 [template]
|
||||
// CHECK:STDOUT: %tuple.type.4: type = tuple_type (i32, i32) [template]
|
||||
// CHECK:STDOUT: %tuple.type.5: type = tuple_type (type, type) [template]
|
||||
// CHECK:STDOUT: %.16: type = ptr_type %tuple.type.4 [template]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: imports {
|
||||
@@ -87,13 +64,6 @@ var d: [i32; 3] = t2;
|
||||
// CHECK:STDOUT: import Core//prelude
|
||||
// CHECK:STDOUT: import Core//prelude/...
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %import_ref.1: %Int32.type = import_ref Core//prelude/types, inst+15, loaded [template = constants.%Int32]
|
||||
// CHECK:STDOUT: %import_ref.2: %ImplicitAs.type.1 = import_ref Core//prelude/operators/as, inst+48, loaded [template = constants.%ImplicitAs]
|
||||
// CHECK:STDOUT: %import_ref.3 = import_ref Core//prelude/operators/as, inst+54, unloaded
|
||||
// CHECK:STDOUT: %import_ref.4: @ImplicitAs.%.1 (%.9) = import_ref Core//prelude/operators/as, inst+76, loaded [symbolic = @ImplicitAs.%.2 (constants.%.13)]
|
||||
// CHECK:STDOUT: %import_ref.5 = import_ref Core//prelude/operators/as, inst+69, unloaded
|
||||
// CHECK:STDOUT: %import_ref.6 = import_ref Core//prelude/operators/as, inst+69, unloaded
|
||||
// CHECK:STDOUT: %import_ref.7 = import_ref Core//prelude/operators/as, inst+69, unloaded
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: file {
|
||||
@@ -154,36 +124,6 @@ var d: [i32; 3] = t2;
|
||||
// CHECK:STDOUT: %d: ref %.2 = bind_name d, %d.var
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: generic interface @ImplicitAs(constants.%Dest: type) {
|
||||
// CHECK:STDOUT: %Dest: type = bind_symbolic_name Dest, 0 [symbolic = %Dest (constants.%Dest)]
|
||||
// CHECK:STDOUT: %Dest.patt: type = symbolic_binding_pattern Dest, 0 [symbolic = %Dest.patt (constants.%Dest.patt)]
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !definition:
|
||||
// CHECK:STDOUT: %ImplicitAs.type: type = facet_type <@ImplicitAs, @ImplicitAs(%Dest)> [symbolic = %ImplicitAs.type (constants.%ImplicitAs.type.2)]
|
||||
// CHECK:STDOUT: %Self: %ImplicitAs.type.2 = bind_symbolic_name Self, 1 [symbolic = %Self (constants.%Self.2)]
|
||||
// CHECK:STDOUT: %Convert.type: type = fn_type @Convert, @ImplicitAs(%Dest) [symbolic = %Convert.type (constants.%Convert.type.1)]
|
||||
// CHECK:STDOUT: %Convert: @ImplicitAs.%Convert.type (%Convert.type.1) = struct_value () [symbolic = %Convert (constants.%Convert.1)]
|
||||
// CHECK:STDOUT: %.1: type = assoc_entity_type @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2), @ImplicitAs.%Convert.type (%Convert.type.1) [symbolic = %.1 (constants.%.9)]
|
||||
// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.9) = assoc_entity element0, imports.%import_ref.6 [symbolic = %.2 (constants.%.10)]
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: interface {
|
||||
// CHECK:STDOUT: !members:
|
||||
// CHECK:STDOUT: .Self = imports.%import_ref.3
|
||||
// CHECK:STDOUT: .Convert = imports.%import_ref.4
|
||||
// CHECK:STDOUT: witness = (imports.%import_ref.5)
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Int32() -> type = "int.make_type_32";
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: generic fn @Convert(constants.%Dest: type, constants.%Self.1: @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2)) {
|
||||
// CHECK:STDOUT: %Dest: type = bind_symbolic_name Dest, 0 [symbolic = %Dest (constants.%Dest)]
|
||||
// CHECK:STDOUT: %ImplicitAs.type: type = facet_type <@ImplicitAs, @ImplicitAs(%Dest)> [symbolic = %ImplicitAs.type (constants.%ImplicitAs.type.2)]
|
||||
// CHECK:STDOUT: %Self: %ImplicitAs.type.2 = bind_symbolic_name Self, 1 [symbolic = %Self (constants.%Self.2)]
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn[%self.param_patt: @Convert.%Self (%Self.2)]() -> @Convert.%Dest (%Dest);
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @__global_init() {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: %.loc18_20: i32 = int_value 1 [template = constants.%.4]
|
||||
@@ -213,37 +153,3 @@ var d: [i32; 3] = t2;
|
||||
// CHECK:STDOUT: return
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @ImplicitAs(constants.%Dest) {
|
||||
// CHECK:STDOUT: %Dest => constants.%Dest
|
||||
// CHECK:STDOUT: %Dest.patt => constants.%Dest
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @ImplicitAs(@ImplicitAs.%Dest) {
|
||||
// CHECK:STDOUT: %Dest => constants.%Dest
|
||||
// CHECK:STDOUT: %Dest.patt => constants.%Dest
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @ImplicitAs(@Convert.%Dest) {
|
||||
// CHECK:STDOUT: %Dest => constants.%Dest
|
||||
// CHECK:STDOUT: %Dest.patt => constants.%Dest
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @Convert(constants.%Dest, constants.%Self.1) {
|
||||
// CHECK:STDOUT: %Dest => constants.%Dest
|
||||
// CHECK:STDOUT: %ImplicitAs.type => constants.%ImplicitAs.type.2
|
||||
// CHECK:STDOUT: %Self => constants.%Self.1
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @ImplicitAs(i32) {
|
||||
// CHECK:STDOUT: %Dest => i32
|
||||
// CHECK:STDOUT: %Dest.patt => i32
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !definition:
|
||||
// CHECK:STDOUT: %ImplicitAs.type => constants.%ImplicitAs.type.3
|
||||
// CHECK:STDOUT: %Self => constants.%Self.2
|
||||
// CHECK:STDOUT: %Convert.type => constants.%Convert.type.2
|
||||
// CHECK:STDOUT: %Convert => constants.%Convert.2
|
||||
// CHECK:STDOUT: %.1 => constants.%.11
|
||||
// CHECK:STDOUT: %.2 => constants.%.12
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
|
||||
@@ -16,12 +16,7 @@ var a: [i32; ];
|
||||
// CHECK:STDOUT: --- fail_undefined_bound.carbon
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: constants {
|
||||
// CHECK:STDOUT: %Int32.type: type = fn_type @Int32 [template]
|
||||
// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template]
|
||||
// CHECK:STDOUT: %Int32: %Int32.type = struct_value () [template]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: file {}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Int32() -> type = "int.make_type_32";
|
||||
// CHECK:STDOUT:
|
||||
|
||||
@@ -20,13 +20,11 @@ fn G() -> i32 {
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: constants {
|
||||
// CHECK:STDOUT: %Int32.type: type = fn_type @Int32 [template]
|
||||
// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template]
|
||||
// CHECK:STDOUT: %Int32: %Int32.type = struct_value () [template]
|
||||
// CHECK:STDOUT: %.1: i32 = int_value 3 [template]
|
||||
// CHECK:STDOUT: %.2: type = array_type %.1, i32 [template]
|
||||
// CHECK:STDOUT: %F.type: type = fn_type @F [template]
|
||||
// CHECK:STDOUT: %F: %F.type = struct_value () [template]
|
||||
// CHECK:STDOUT: %.3: type = ptr_type %.2 [template]
|
||||
// CHECK:STDOUT: %G.type: type = fn_type @G [template]
|
||||
// CHECK:STDOUT: %G: %G.type = struct_value () [template]
|
||||
// CHECK:STDOUT: %.4: i32 = int_value 1 [template]
|
||||
@@ -42,7 +40,6 @@ fn G() -> i32 {
|
||||
// CHECK:STDOUT: import Core//prelude
|
||||
// CHECK:STDOUT: import Core//prelude/...
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %import_ref: %Int32.type = import_ref Core//prelude/types, inst+15, loaded [template = constants.%Int32]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: file {
|
||||
@@ -90,8 +87,6 @@ fn G() -> i32 {
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Int32() -> type = "int.make_type_32";
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @F(%arr.param_patt: %.2, %i.param_patt: i32) -> i32 {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: %arr.ref: %.2 = name_ref arr, %arr
|
||||
|
||||
@@ -23,7 +23,6 @@ fn G(T:! type) {
|
||||
// CHECK:STDOUT: %G: %G.type = struct_value () [template]
|
||||
// CHECK:STDOUT: %.1: i32 = int_value 0 [template]
|
||||
// CHECK:STDOUT: %.2: type = array_type %.1, %T [symbolic]
|
||||
// CHECK:STDOUT: %.3: type = ptr_type %.2 [symbolic]
|
||||
// CHECK:STDOUT: %array: %.2 = tuple_value () [symbolic]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
|
||||
@@ -15,11 +15,9 @@ var b: i32 = a[{.index = 2}.index];
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: constants {
|
||||
// CHECK:STDOUT: %Int32.type: type = fn_type @Int32 [template]
|
||||
// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template]
|
||||
// CHECK:STDOUT: %Int32: %Int32.type = struct_value () [template]
|
||||
// CHECK:STDOUT: %.1: i32 = int_value 3 [template]
|
||||
// CHECK:STDOUT: %.2: type = array_type %.1, i32 [template]
|
||||
// CHECK:STDOUT: %.3: type = ptr_type %.2 [template]
|
||||
// CHECK:STDOUT: %.4: i32 = int_value 1 [template]
|
||||
// CHECK:STDOUT: %.5: i32 = int_value 2 [template]
|
||||
// CHECK:STDOUT: %tuple.type: type = tuple_type (i32, i32, i32) [template]
|
||||
@@ -35,7 +33,6 @@ var b: i32 = a[{.index = 2}.index];
|
||||
// CHECK:STDOUT: import Core//prelude
|
||||
// CHECK:STDOUT: import Core//prelude/...
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %import_ref: %Int32.type = import_ref Core//prelude/types, inst+15, loaded [template = constants.%Int32]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: file {
|
||||
@@ -59,8 +56,6 @@ var b: i32 = a[{.index = 2}.index];
|
||||
// CHECK:STDOUT: %b: ref i32 = bind_name b, %b.var
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Int32() -> type = "int.make_type_32";
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @__global_init() {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: %.loc11_20: i32 = int_value 1 [template = constants.%.4]
|
||||
|
||||
@@ -14,11 +14,9 @@ var a: [i32; 9] = (1, 2, 3, 4, 5, 6, 7, 8, 9);
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: constants {
|
||||
// CHECK:STDOUT: %Int32.type: type = fn_type @Int32 [template]
|
||||
// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template]
|
||||
// CHECK:STDOUT: %Int32: %Int32.type = struct_value () [template]
|
||||
// CHECK:STDOUT: %.1: i32 = int_value 9 [template]
|
||||
// CHECK:STDOUT: %.2: type = array_type %.1, i32 [template]
|
||||
// CHECK:STDOUT: %.3: type = ptr_type %.2 [template]
|
||||
// CHECK:STDOUT: %.4: i32 = int_value 1 [template]
|
||||
// CHECK:STDOUT: %.5: i32 = int_value 2 [template]
|
||||
// CHECK:STDOUT: %.6: i32 = int_value 3 [template]
|
||||
@@ -38,7 +36,6 @@ var a: [i32; 9] = (1, 2, 3, 4, 5, 6, 7, 8, 9);
|
||||
// CHECK:STDOUT: import Core//prelude
|
||||
// CHECK:STDOUT: import Core//prelude/...
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %import_ref: %Int32.type = import_ref Core//prelude/types, inst+15, loaded [template = constants.%Int32]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: file {
|
||||
@@ -56,8 +53,6 @@ var a: [i32; 9] = (1, 2, 3, 4, 5, 6, 7, 8, 9);
|
||||
// CHECK:STDOUT: %a: ref %.2 = bind_name a, %a.var
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Int32() -> type = "int.make_type_32";
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @__global_init() {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: %.loc11_20: i32 = int_value 1 [template = constants.%.4]
|
||||
|
||||
Reference in New Issue
Block a user