llvm.org GIT mirror llvm / 6f025c1
gold: Simplify. Do not unnecessarily enumerate Obj's symbols. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@281437 91177308-0d34-0410-b5e6-96231b3b80d8 Peter Collingbourne 4 years ago
1 changed file(s) with 2 addition(s) and 6 deletion(s). Raw diff Collapse all Expand all
567567 message(LDPL_FATAL, "Could not read bitcode from file : %s",
568568 toString(ObjOrErr.takeError()).c_str());
569569
570 InputFile &Obj = **ObjOrErr;
571
572570 unsigned SymNum = 0;
573571 std::vector Resols(F.syms.size());
574 for (LLVM_ATTRIBUTE_UNUSED auto &ObjSym : Obj.symbols()) {
575 ld_plugin_symbol &Sym = F.syms[SymNum];
576 SymbolResolution &R = Resols[SymNum];
577 ++SymNum;
572 for (ld_plugin_symbol &Sym : F.syms) {
573 SymbolResolution &R = Resols[SymNum++];
578574
579575 ld_plugin_symbol_resolution Resolution =
580576 (ld_plugin_symbol_resolution)Sym.resolution;