[LLVMbugs] [Bug 23406] New: Metal internal compiler error

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Mon May 4 07:38:43 PDT 2015


https://llvm.org/bugs/show_bug.cgi?id=23406

            Bug ID: 23406
           Summary: Metal internal compiler error
           Product: new-bugs
           Version: unspecified
          Hardware: Macintosh
                OS: MacOS X
            Status: NEW
          Severity: release blocker
          Priority: P
         Component: new bugs
          Assignee: unassignedbugs at nondot.org
          Reporter: h.hamm at dsfishlabs.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

Created attachment 14279
  --> https://llvm.org/bugs/attachment.cgi?id=14279&action=edit
Metal Shader File that causes the error

Recently tried to compile an autogenerated metal shader and got an internal
compiler error and a notice that I should report a bug. The used metal shader
is assigend as attachment and here comes the stack trace:

STACK TRACE:
<MyProjectDir Prompt>$
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/usr/bin/metal
metalshader.metal -std=ios-metal1.0
metalshader.metal:284:16: warning: unused variable 'normalDirL'
[-Wunused-variable]
                        const half3 normalDirL = in.v_normalDirL;
               ^
metalshader.metal:291:10: warning: unused variable 'diffuseLight'
[-Wunused-variable]
                float3 diffuseLight = float3(0.0,0.0,0.0);
         ^
metalshader.metal:255:9: warning: unused variable 'ambientocclusionTexel'
[-Wunused-variable]
                        half ambientocclusionTexel = ambientocclusionTexture.a;
        ^
metalshader.metal:253:9: warning: unused variable 'glossTexel'
[-Wunused-variable]
                        half glossTexel = half(materialUniforms.Gloss_Amount);
        ^
metalshader.metal:104:25: warning: unused variable 'MAX_LIGHTS'
[-Wunused-const-variable]
constexpr constant uint MAX_LIGHTS = 0;
                        ^
0  metal                    0x000000010c8c6a68
llvm::SmallVectorImpl<char>::swap(llvm::SmallVectorImpl<char>&) + 14488
1  metal                    0x000000010c8c6e54
llvm::SmallVectorImpl<char>::swap(llvm::SmallVectorImpl<char>&) + 15492
2  libsystem_platform.dylib 0x00007fff87039f1a _sigtramp + 26
3  metal                    0x000000010c907b95 bool
std::__1::__insertion_sort_incomplete<llvm::less_first&,
std::__1::pair<unsigned int, llvm::StoreInst*>*>(std::__1::pair<unsigned int,
llvm::StoreInst*>*, std::__1::pair<unsigned int, llvm::StoreInst*>*,
llvm::less_first&) + 32581
4  metal                    0x000000010ce7ff15
std::__1::__split_buffer<std::__1::pair<llvm::PointerIntPair<llvm::CallGraphNode*,
1u, unsigned int, llvm::PointerLikeTypeTraits<llvm::CallGraphNode*> >,
llvm::mapped_iterator<std::__1::__wrap_iter<std::__1::pair<llvm::WeakVH,
llvm::CallGraphNode*>*>,
std::__1::pointer_to_unary_function<std::__1::pair<llvm::WeakVH,
llvm::CallGraphNode*>, llvm::CallGraphNode*> > >,
std::__1::allocator<std::__1::pair<llvm::PointerIntPair<llvm::CallGraphNode*,
1u, unsigned int, llvm::PointerLikeTypeTraits<llvm::CallGraphNode*> >,
llvm::mapped_iterator<std::__1::__wrap_iter<std::__1::pair<llvm::WeakVH,
llvm::CallGraphNode*>*>,
std::__1::pointer_to_unary_function<std::__1::pair<llvm::WeakVH,
llvm::CallGraphNode*>, llvm::CallGraphNode*> > > >&>::~__split_buffer() + 1711
5  metal                    0x000000010c568dc6
std::__1::__tree<std::__1::__value_type<llvm::Function const*,
llvm::CallGraphNode*>, std::__1::__map_value_compare<llvm::Function const*,
std::__1::__value_type<llvm::Function const*, llvm::CallGraphNode*>,
std::__1::less<llvm::Function const*>, true>,
std::__1::allocator<std::__1::__value_type<llvm::Function const*,
llvm::CallGraphNode*> >
>::destroy(std::__1::__tree_node<std::__1::__value_type<llvm::Function const*,
llvm::CallGraphNode*>, void*>*) + 2726
6  metal                    0x000000010c4a643f void
llvm::DeleteContainerSeconds<llvm::DenseMap<llvm::Type*, llvm::UndefValue*,
llvm::DenseMapInfo<llvm::Type*> > >(llvm::DenseMap<llvm::Type*,
llvm::UndefValue*, llvm::DenseMapInfo<llvm::Type*> >&) + 31599
7  metal                    0x000000010cc4e51f
std::__1::__vector_base<llvm::coverage::CounterMappingRegion,
std::__1::allocator<llvm::coverage::CounterMappingRegion> >::~__vector_base() +
64371
8  metal                    0x000000010cd10a11
llvm::SmallVectorTemplateBase<llvm::DenseMap<clang::BaseSubobject, unsigned
long long, llvm::DenseMapInfo<clang::BaseSubobject> >, false>::grow(unsigned
long) + 11685
9  metal                    0x000000010ce80736
std::__1::__split_buffer<std::__1::pair<llvm::PointerIntPair<llvm::CallGraphNode*,
1u, unsigned int, llvm::PointerLikeTypeTraits<llvm::CallGraphNode*> >,
llvm::mapped_iterator<std::__1::__wrap_iter<std::__1::pair<llvm::WeakVH,
llvm::CallGraphNode*>*>,
std::__1::pointer_to_unary_function<std::__1::pair<llvm::WeakVH,
llvm::CallGraphNode*>, llvm::CallGraphNode*> > >,
std::__1::allocator<std::__1::pair<llvm::PointerIntPair<llvm::CallGraphNode*,
1u, unsigned int, llvm::PointerLikeTypeTraits<llvm::CallGraphNode*> >,
llvm::mapped_iterator<std::__1::__wrap_iter<std::__1::pair<llvm::WeakVH,
llvm::CallGraphNode*>*>,
std::__1::pointer_to_unary_function<std::__1::pair<llvm::WeakVH,
llvm::CallGraphNode*>, llvm::CallGraphNode*> > > >&>::~__split_buffer() + 3792
10 metal                    0x000000010cd0fd3a
llvm::SmallVectorTemplateBase<llvm::DenseMap<clang::BaseSubobject, unsigned
long long, llvm::DenseMapInfo<clang::BaseSubobject> >, false>::grow(unsigned
long) + 8398
11 metal                    0x000000010ce04b00
std::__1::__tree<std::__1::__value_type<clang::edit::FileOffset,
clang::edit::EditedSource::FileEdit>,
std::__1::__map_value_compare<clang::edit::FileOffset,
std::__1::__value_type<clang::edit::FileOffset,
clang::edit::EditedSource::FileEdit>, std::__1::less<clang::edit::FileOffset>,
true>, std::__1::allocator<std::__1::__value_type<clang::edit::FileOffset,
clang::edit::EditedSource::FileEdit> >
>::destroy(std::__1::__tree_node<std::__1::__value_type<clang::edit::FileOffset,
clang::edit::EditedSource::FileEdit>, void*>*) + 4720
12 metal                    0x000000010cde16c6
std::__1::__vector_base<clang::CompilerInstance*,
std::__1::allocator<clang::CompilerInstance*> >::~__vector_base() + 13966
13 metal                    0x000000010ce2d349 char const*
std::__1::__search<std::__1::__equal_to<char, char>&, char const*, char
const*>(char const*, char const*, char const*, char const*,
std::__1::__equal_to<char, char>&, std::__1::random_access_iterator_tag,
std::__1::random_access_iterator_tag) + 3609
14 metal                    0x000000010be9aa54
std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>,
std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char,
std::__1::char_traits<char>, std::__1::allocator<char> > > >::deallocate() +
3092
15 metal                    0x000000010be9d236
std::__1::__vector_base<llvm::AssertingVH<llvm::Instruction>,
std::__1::allocator<llvm::AssertingVH<llvm::Instruction> > >::~__vector_base()
+ 8070
16 libdyld.dylib            0x00007fff88ecd5c9 start + 1
metal: error: unable to execute command: Segmentation fault: 11
metal: error: clang frontend command failed due to signal (use -v to see
invocation)
LLVM version 3.5 
Target: air64-apple-darwin14.3.0
Thread model: posix
metal: note: diagnostic msg: PLEASE submit a bug report to
http://llvm.org/bugs/ and include the crash backtrace, preprocessed source, and
associated run script.
metal: note: diagnostic msg: 
********************

PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT:
Preprocessed source(s) and associated run script(s) are located at:
metal: note: diagnostic msg:
/var/folders/qy/414mvr4108s6_0n26mcs8pn80000gn/T/metalshader-f75c5a.metal
metal: note: diagnostic msg:
/var/folders/qy/414mvr4108s6_0n26mcs8pn80000gn/T/metalshader-f75c5a.sh
metal: note: diagnostic msg: 

********************
<MyProjectDir Prompt>$
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/usr/bin/metal
--version
LLVM version 3.5 
Target: x86_64-apple-darwin14.3.0
Thread model: posix

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20150504/3e5dab9f/attachment.html>


More information about the llvm-bugs mailing list