MaskRay added a comment.

> However, on AIX, the current binder can NOT discard the weak symbols if we 
> put all of them into the same csect, as binder can NOT discard only part of a 
> csect.

"as binder can NOT discard only part of a csect." this part caused confusion to 
me...

> CountersOffset is now 0x1ffffffffffffda3 ( CounterPtr - CountersDelta / 
> sizeof(unit64_6))
>
> CountersOffset > MaxNumCounters !

It is true that there are two pairs of weak profc/profd, but the first profc 
has a zero value, so I assume that it is fine?

The second pair of profc/profd has correct value.

I haven't verified but it is possible that PGO picks the first pair (zero 
value) and have an incorrect counter for `foo`.

---

Does your example imply that the weak symbol `__profc_foo` has 2 definitions 
with conflicting values? 
I presume it can cause more fallout.
Any idea whether the linker bug will be fixed?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D110422/new/

https://reviews.llvm.org/D110422

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to