Index: include/llvm/Bitcode/LLVMBitCodes.h =================================================================== --- include/llvm/Bitcode/LLVMBitCodes.h +++ include/llvm/Bitcode/LLVMBitCodes.h @@ -34,7 +34,8 @@ CONSTANTS_BLOCK_ID, FUNCTION_BLOCK_ID, - UNUSED_ID1, + // Valid inside vendor specific toolchains only, discarded by open-source + VENDOR_RESERVED_ID, VALUE_SYMTAB_BLOCK_ID, METADATA_BLOCK_ID, Index: test/Bitcode/vendor_block.test =================================================================== --- /dev/null +++ test/Bitcode/vendor_block.test @@ -0,0 +1,6 @@ +# Check that a global vendor block is correctly ignored +# and skipped by the vanilla bitcode reader + +; RUN: opt -S %p/Inputs/vendor_block.bc | FileCheck %s +; CHECK: target triple = "x86_64-apple-macosx10.9" +