Thanks for using Compiler Explorer
Sponsors
Jakt
C++
Ada
Algol68
Analysis
Android Java
Android Kotlin
Assembly
C
C3
Carbon
C with Coccinelle
C++ with Coccinelle
C++ (Circle)
CIRCT
Clean
CMake
CMakeScript
COBOL
C++ for OpenCL
MLIR
Cppx
Cppx-Blue
Cppx-Gold
Cpp2-cppfront
Crystal
C#
CUDA C++
D
Dart
Elixir
Erlang
Fortran
F#
GLSL
Go
Haskell
HLSL
Hook
Hylo
IL
ispc
Java
Julia
Kotlin
LLVM IR
LLVM MIR
Modula-2
Mojo
Nim
Numba
Nix
Objective-C
Objective-C++
OCaml
Odin
OpenCL C
Pascal
Pony
PTX
Python
Racket
Raku
Ruby
Rust
Sail
Snowball
Scala
Slang
Solidity
Spice
SPIR-V
Swift
LLVM TableGen
Toit
Triton
TypeScript Native
V
Vala
Visual Basic
Vyper
WASM
Zig
Javascript
GIMPLE
Ygen
sway
llvm source #1
Output
Compile to binary object
Link to binary
Execute the code
Intel asm syntax
Demangle identifiers
Verbose demangling
Filters
Unused labels
Library functions
Directives
Comments
Horizontal whitespace
Debug intrinsics
Compiler
clang (assertions trunk)
clang (trunk)
clang 10.0.0
clang 10.0.1
clang 11.0.0
clang 11.0.1
clang 12.0.0
clang 12.0.1
clang 13.0.0
clang 14.0.0
clang 15.0.0
clang 16.0.0
clang 17.0.1
clang 18.1.0
clang 19.1.0
clang 20.1.0
clang 4.0.1
clang 5.0.0
clang 6.0.0
clang 7.0.0
clang 8.0.0
clang 9.0.0
hexagon-clang 16.0.5
llc (assertions trunk)
llc (trunk)
llc 10.0.0
llc 10.0.1
llc 11.0.0
llc 11.0.1
llc 12.0.0
llc 12.0.1
llc 13.0.0
llc 14.0.0
llc 15.0.0
llc 16.0.0
llc 17.0.1
llc 18.1.0
llc 19.1.0
llc 20.1.0
llc 3.2
llc 3.3
llc 3.9.1
llc 4.0.0
llc 4.0.1
llc 5.0.0
llc 6.0.0
llc 7.0.0
llc 8.0.0
llc 9.0.0
opt (assertions trunk)
opt (trunk)
opt 10.0.0
opt 10.0.1
opt 11.0.0
opt 11.0.1
opt 12.0.0
opt 12.0.1
opt 13.0.0
opt 14.0.0
opt 15.0.0
opt 16.0.0
opt 17.0.1
opt 18.1.0
opt 19.1.0
opt 20.1.0
opt 3.2
opt 3.3
opt 3.9.1
opt 4.0.0
opt 4.0.1
opt 5.0.0
opt 6.0.0
opt 7.0.0
opt 8.0.0
opt 9.0.0
Options
Source code
; ModuleID = 'target/release/deps/repro_117902-56f6dc5b8960896e.repro_117902.7020c2560ba627c6-cgu.0.rcgu.bc' source_filename = "repro_117902.7020c2560ba627c6-cgu.0" target datalayout = "e-m:o-i64:64-i128:128-n32:64-S128" target triple = "arm64-apple-macosx11.0.0" @anon.64ad042c50cb23e4161bf187d5f7c9d0.0 = private unnamed_addr constant <{ ptr, [16 x i8], ptr, ptr, ptr }> <{ ptr @"_ZN4core3ptr85drop_in_place$LT$std..rt..lang_start$LT$$LP$$RP$$GT$..$u7b$$u7b$closure$u7d$$u7d$$GT$17h3a1b0748b2c25cccE", [16 x i8] c"\08\00\00\00\00\00\00\00\08\00\00\00\00\00\00\00", ptr @"_ZN4core3ops8function6FnOnce40call_once$u7b$$u7b$vtable.shim$u7d$$u7d$17h512928ff3374a545E", ptr @"_ZN3std2rt10lang_start28_$u7b$$u7b$closure$u7d$$u7d$17h6dd4fb201eb649c3E", ptr @"_ZN3std2rt10lang_start28_$u7b$$u7b$closure$u7d$$u7d$17h6dd4fb201eb649c3E" }>, align 8 ; Function Attrs: noinline nounwind define internal fastcc void @_ZN3std10sys_common9backtrace28__rust_begin_short_backtrace17hd873549178bc3496E(ptr nocapture noundef nonnull readonly %0) unnamed_addr #0 { tail call void %0() #7 tail call void asm sideeffect "", "~{memory}"() #7, !srcloc !3 ret void } ; Function Attrs: noinline nounwind define hidden noundef i64 @_ZN3std2rt10lang_start17h67fe27acf642c52aE(ptr noundef nonnull %0, i64 noundef %1, ptr noundef %2, i8 noundef %3) unnamed_addr #0 { %5 = alloca ptr, align 8 call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) store ptr %0, ptr %5, align 8 %6 = call noundef i64 @_ZN3std2rt19lang_start_internal17h845b17c5405e1c05E(ptr noundef nonnull align 1 %5, ptr noalias noundef nonnull readonly align 8 dereferenceable(24) @anon.64ad042c50cb23e4161bf187d5f7c9d0.0, i64 noundef %1, ptr noundef %2, i8 noundef %3) #7 call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) ret i64 %6 } ; Function Attrs: inlinehint nounwind define internal noundef i32 @"_ZN3std2rt10lang_start28_$u7b$$u7b$closure$u7d$$u7d$17h6dd4fb201eb649c3E"(ptr noalias nocapture noundef readonly align 8 dereferenceable(8) %0) unnamed_addr #1 { %2 = load ptr, ptr %0, align 8, !nonnull !4, !noundef !4 tail call fastcc void @_ZN3std10sys_common9backtrace28__rust_begin_short_backtrace17hd873549178bc3496E(ptr noundef nonnull %2) #7 ret i32 0 } ; Function Attrs: inlinehint nounwind define internal noundef i32 @"_ZN4core3ops8function6FnOnce40call_once$u7b$$u7b$vtable.shim$u7d$$u7d$17h512928ff3374a545E"(ptr nocapture noundef readonly %0) unnamed_addr #1 { %2 = load ptr, ptr %0, align 8, !nonnull !4, !noundef !4 tail call fastcc void @_ZN3std10sys_common9backtrace28__rust_begin_short_backtrace17hd873549178bc3496E(ptr noundef nonnull %2) #7, !noalias !5 ret i32 0 } ; Function Attrs: inlinehint mustprogress nofree norecurse nosync nounwind willreturn memory(none) define internal void @"_ZN4core3ptr85drop_in_place$LT$std..rt..lang_start$LT$$LP$$RP$$GT$..$u7b$$u7b$closure$u7d$$u7d$$GT$17h3a1b0748b2c25cccE"(ptr noalias nocapture align 8 %0) unnamed_addr #2 { ret void } ; Function Attrs: nounwind define internal void @_ZN12repro_1179024main17h5bde0b8e73de524bE() unnamed_addr #3 { tail call void @call_from_main() #7 ret void } ; Function Attrs: noinline nounwind define dso_local void @call_from_main() unnamed_addr #0 { %1 = alloca { { i32, [2 x i32] } }, align 4 store i32 1, ptr %1, align 4 call void @device_create_texture(ptr noalias nocapture noundef nonnull readonly align 4 dereferenceable(12) %1) #7 ret void } ; Function Attrs: noinline nounwind define dso_local void @device_create_texture(ptr noalias nocapture noundef readonly align 4 dereferenceable(12) %0) unnamed_addr #0 { %2 = alloca { i32, [2 x i32] }, align 4 call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %2) call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %2, ptr noundef nonnull align 4 dereferenceable(12) %0, i64 12, i1 false) %3 = load i32, ptr %2, align 4, !range !8, !noundef !4 %4 = getelementptr inbounds i8, ptr %2, i64 4 %5 = load i8, ptr %4, align 4 %6 = tail call fastcc noundef zeroext i1 @_ZN12repro_11790213TextureFormat17required_features17h5e4d5de64322154bE(i32 %3, i8 %5) #7 tail call fastcc void @_ZN12repro_1179027Feature4used17hf92ae82be52470caE(i1 noundef zeroext %6) #7 call fastcc void @_ZN12repro_11790213TextureFormat4used17ha7a35183d36eae1cE(ptr noalias noundef nonnull readonly align 4 dereferenceable(12) %2) #7 call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %2) ret void } ; Function Attrs: noinline nounwind define internal fastcc void @_ZN12repro_1179027Feature4used17hf92ae82be52470caE(i1 noundef zeroext %0) unnamed_addr #0 { %2 = alloca i8, align 1 call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %2) %3 = zext i1 %0 to i8 store i8 %3, ptr %2, align 1 call void asm sideeffect "", "r,~{memory}"(ptr nonnull %2) #7, !srcloc !3 call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %2) ret void } ; Function Attrs: noinline nounwind define internal fastcc void @_ZN12repro_11790213TextureFormat4used17ha7a35183d36eae1cE(ptr noalias noundef readonly align 4 dereferenceable(12) %0) unnamed_addr #0 { %2 = alloca ptr, align 8 call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %2) store ptr %0, ptr %2, align 8 call void asm sideeffect "", "r,~{memory}"(ptr nonnull %2) #7, !srcloc !3 call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) ret void } ; Function Attrs: mustprogress nofree noinline norecurse nosync nounwind willreturn memory(none) define internal fastcc noundef zeroext i1 @_ZN12repro_11790213TextureFormat17required_features17h5e4d5de64322154bE(i32 %0, i8 %1) unnamed_addr #4 { switch i32 %0, label %3 [ i32 0, label %8 i32 1, label %4 i32 2, label %5 i32 3, label %6 ] 3: ; preds = %2 unreachable 4: ; preds = %2 br label %8 5: ; preds = %2 br label %8 6: ; preds = %2 %7 = icmp eq i8 %1, 0 br label %8 8: ; preds = %6, %5, %4, %2 %9 = phi i1 [ true, %5 ], [ true, %4 ], [ false, %2 ], [ %7, %6 ] ret i1 %9 } ; Function Attrs: nounwind declare noundef i64 @_ZN3std2rt19lang_start_internal17h845b17c5405e1c05E(ptr noundef nonnull align 1, ptr noalias noundef readonly align 8 dereferenceable(24), i64 noundef, ptr noundef, i8 noundef) unnamed_addr #3 ; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite) declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #5 ; Function Attrs: nounwind define i32 @main(i32 %0, ptr %1) unnamed_addr #3 { %3 = sext i32 %0 to i64 %4 = tail call i64 @_ZN3std2rt10lang_start17h67fe27acf642c52aE(ptr @_ZN12repro_1179024main17h5bde0b8e73de524bE, i64 %3, ptr %1, i8 0) %5 = trunc i64 %4 to i32 ret i32 %5 } ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #6 ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #6 attributes #0 = { noinline nounwind "frame-pointer"="non-leaf" "target-cpu"="apple-m1" } attributes #1 = { inlinehint nounwind "frame-pointer"="non-leaf" "target-cpu"="apple-m1" } attributes #2 = { inlinehint mustprogress nofree norecurse nosync nounwind willreturn memory(none) "frame-pointer"="non-leaf" "target-cpu"="apple-m1" } attributes #3 = { nounwind "frame-pointer"="non-leaf" "target-cpu"="apple-m1" } attributes #4 = { mustprogress nofree noinline norecurse nosync nounwind willreturn memory(none) "frame-pointer"="non-leaf" "target-cpu"="apple-m1" } attributes #5 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) } attributes #6 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) } attributes #7 = { nounwind } !llvm.module.flags = !{!0, !1} !llvm.ident = !{!2} !0 = !{i32 8, !"PIC Level", i32 2} !1 = !{i32 7, !"PIE Level", i32 2} !2 = !{!"rustc version 1.76.0-nightly (e9013ac0e 2023-12-05)"} !3 = !{i32 1008490} !4 = !{} !5 = !{!6} !6 = distinct !{!6, !7, !"_ZN3std2rt10lang_start28_$u7b$$u7b$closure$u7d$$u7d$17h6dd4fb201eb649c3E: argument 0"} !7 = distinct !{!7, !"_ZN3std2rt10lang_start28_$u7b$$u7b$closure$u7d$$u7d$17h6dd4fb201eb649c3E"} !8 = !{i32 0, i32 4} ^0 = module: (path: "target/release/deps/repro_117902-56f6dc5b8960896e.repro_117902.7020c2560ba627c6-cgu.0.rcgu.bc", hash: (588908617, 3882433785, 1436305396, 120652418, 367191557)) ^1 = gv: (name: "_ZN4core3ptr85drop_in_place$LT$std..rt..lang_start$LT$$LP$$RP$$GT$..$u7b$$u7b$closure$u7d$$u7d$$GT$17h3a1b0748b2c25cccE", summaries: (function: (module: ^0, flags: (linkage: internal, visibility: default, notEligibleToImport: 0, live: 0, dsoLocal: 1, canAutoHide: 0), insts: 1, funcFlags: (readNone: 1, readOnly: 0, noRecurse: 1, returnDoesNotAlias: 0, noInline: 0, alwaysInline: 0, noUnwind: 1, mayThrow: 0, hasUnknownCall: 0, mustBeUnreachable: 0)))) ; guid = 26047620286636215 ^2 = gv: (name: "llvm.memcpy.p0.p0.i64") ; guid = 2699563562842851132 ^3 = gv: (name: "_ZN12repro_11790213TextureFormat17required_features17h5e4d5de64322154bE", summaries: (function: (module: ^0, flags: (linkage: internal, visibility: default, notEligibleToImport: 0, live: 0, dsoLocal: 1, canAutoHide: 0), insts: 8, funcFlags: (readNone: 1, readOnly: 0, noRecurse: 1, returnDoesNotAlias: 0, noInline: 1, alwaysInline: 0, noUnwind: 1, mayThrow: 0, hasUnknownCall: 0, mustBeUnreachable: 0)))) ; guid = 4172334787452303150 ^4 = gv: (name: "llvm.lifetime.start.p0") ; guid = 4736283418132453162 ^5 = gv: (name: "call_from_main", summaries: (function: (module: ^0, flags: (linkage: external, visibility: default, notEligibleToImport: 0, live: 0, dsoLocal: 1, canAutoHide: 0), insts: 4, funcFlags: (readNone: 0, readOnly: 0, noRecurse: 0, returnDoesNotAlias: 0, noInline: 1, alwaysInline: 0, noUnwind: 1, mayThrow: 0, hasUnknownCall: 0, mustBeUnreachable: 0), calls: ((callee: ^15))))) ; guid = 6035738942445582630 ^6 = gv: (name: "anon.64ad042c50cb23e4161bf187d5f7c9d0.0", summaries: (variable: (module: ^0, flags: (linkage: private, visibility: default, notEligibleToImport: 0, live: 0, dsoLocal: 1, canAutoHide: 0), varFlags: (readonly: 1, writeonly: 0, constant: 1), refs: (^13, ^16, ^1)))) ; guid = 9670865711561157444 ^7 = gv: (name: "_ZN12repro_1179027Feature4used17hf92ae82be52470caE", summaries: (function: (module: ^0, flags: (linkage: internal, visibility: default, notEligibleToImport: 0, live: 0, dsoLocal: 1, canAutoHide: 0), insts: 7, funcFlags: (readNone: 0, readOnly: 0, noRecurse: 0, returnDoesNotAlias: 0, noInline: 1, alwaysInline: 0, noUnwind: 1, mayThrow: 0, hasUnknownCall: 1, mustBeUnreachable: 0)))) ; guid = 9674694493251075121 ^8 = gv: (name: "_ZN12repro_11790213TextureFormat4used17ha7a35183d36eae1cE", summaries: (function: (module: ^0, flags: (linkage: internal, visibility: default, notEligibleToImport: 0, live: 0, dsoLocal: 1, canAutoHide: 0), insts: 6, funcFlags: (readNone: 0, readOnly: 0, noRecurse: 0, returnDoesNotAlias: 0, noInline: 1, alwaysInline: 0, noUnwind: 1, mayThrow: 0, hasUnknownCall: 1, mustBeUnreachable: 0)))) ; guid = 9689809968903449149 ^9 = gv: (name: "_ZN3std2rt19lang_start_internal17h845b17c5405e1c05E") ; guid = 9848804123585259338 ^10 = gv: (name: "_ZN3std10sys_common9backtrace28__rust_begin_short_backtrace17hd873549178bc3496E", summaries: (function: (module: ^0, flags: (linkage: internal, visibility: default, notEligibleToImport: 0, live: 0, dsoLocal: 1, canAutoHide: 0), insts: 3, funcFlags: (readNone: 0, readOnly: 0, noRecurse: 0, returnDoesNotAlias: 0, noInline: 1, alwaysInline: 0, noUnwind: 1, mayThrow: 0, hasUnknownCall: 1, mustBeUnreachable: 0)))) ; guid = 12833174623530944153 ^11 = gv: (name: "llvm.lifetime.end.p0") ; guid = 13244677477227836793 ^12 = gv: (name: "_ZN12repro_1179024main17h5bde0b8e73de524bE", summaries: (function: (module: ^0, flags: (linkage: internal, visibility: default, notEligibleToImport: 0, live: 0, dsoLocal: 1, canAutoHide: 0), insts: 2, funcFlags: (readNone: 0, readOnly: 0, noRecurse: 0, returnDoesNotAlias: 0, noInline: 0, alwaysInline: 0, noUnwind: 1, mayThrow: 0, hasUnknownCall: 0, mustBeUnreachable: 0), calls: ((callee: ^5))))) ; guid = 14312892286285863117 ^13 = gv: (name: "_ZN3std2rt10lang_start28_$u7b$$u7b$closure$u7d$$u7d$17h6dd4fb201eb649c3E", summaries: (function: (module: ^0, flags: (linkage: internal, visibility: default, notEligibleToImport: 0, live: 0, dsoLocal: 1, canAutoHide: 0), insts: 3, funcFlags: (readNone: 0, readOnly: 0, noRecurse: 0, returnDoesNotAlias: 0, noInline: 0, alwaysInline: 0, noUnwind: 1, mayThrow: 0, hasUnknownCall: 0, mustBeUnreachable: 0), calls: ((callee: ^10))))) ; guid = 15308066350717154503 ^14 = gv: (name: "main", summaries: (function: (module: ^0, flags: (linkage: external, visibility: default, notEligibleToImport: 0, live: 0, dsoLocal: 0, canAutoHide: 0), insts: 4, funcFlags: (readNone: 0, readOnly: 0, noRecurse: 0, returnDoesNotAlias: 0, noInline: 0, alwaysInline: 0, noUnwind: 1, mayThrow: 0, hasUnknownCall: 0, mustBeUnreachable: 0), calls: ((callee: ^17)), refs: (^12)))) ; guid = 15822663052811949562 ^15 = gv: (name: "device_create_texture", summaries: (function: (module: ^0, flags: (linkage: external, visibility: default, notEligibleToImport: 0, live: 0, dsoLocal: 1, canAutoHide: 0), insts: 11, funcFlags: (readNone: 0, readOnly: 0, noRecurse: 0, returnDoesNotAlias: 0, noInline: 1, alwaysInline: 0, noUnwind: 1, mayThrow: 0, hasUnknownCall: 0, mustBeUnreachable: 0), calls: ((callee: ^3), (callee: ^7), (callee: ^8))))) ; guid = 17107844002317553301 ^16 = gv: (name: "_ZN4core3ops8function6FnOnce40call_once$u7b$$u7b$vtable.shim$u7d$$u7d$17h512928ff3374a545E", summaries: (function: (module: ^0, flags: (linkage: internal, visibility: default, notEligibleToImport: 0, live: 0, dsoLocal: 1, canAutoHide: 0), insts: 3, funcFlags: (readNone: 0, readOnly: 0, noRecurse: 0, returnDoesNotAlias: 0, noInline: 0, alwaysInline: 0, noUnwind: 1, mayThrow: 0, hasUnknownCall: 0, mustBeUnreachable: 0), calls: ((callee: ^10))))) ; guid = 17770695831011789681 ^17 = gv: (name: "_ZN3std2rt10lang_start17h67fe27acf642c52aE", summaries: (function: (module: ^0, flags: (linkage: external, visibility: hidden, notEligibleToImport: 0, live: 0, dsoLocal: 1, canAutoHide: 0), insts: 6, funcFlags: (readNone: 0, readOnly: 0, noRecurse: 0, returnDoesNotAlias: 0, noInline: 1, alwaysInline: 0, noUnwind: 1, mayThrow: 0, hasUnknownCall: 0, mustBeUnreachable: 0), calls: ((callee: ^9)), refs: (^6)))) ; guid = 17829067331104480233 ^18 = blockcount: 0
Become a Patron
Sponsor on GitHub
Donate via PayPal
Compiler Explorer Shop
Source on GitHub
Mailing list
Installed libraries
Wiki
Report an issue
How it works
Contact the author
CE on Mastodon
CE on Bluesky
Statistics
Changelog
Version tree