This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: PATCH: Properly check the end of basic block


On Thu, Nov 18, 2010 at 12:36 AM, H.J. Lu <hjl.tools@gmail.com> wrote:

> Here is the patch for
>
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46519
>
> We have 2 blocks pointing to each others. This patch first scans
> all blocks without moving vzeroupper so that we can have accurate
> information about upper 128bits at block entry.

This introduces another insn scanning pass, almost the same as
existing vzeroupper pass (modulo CALL_INSN/JUMP_INSN handling).

So, if I understand correctly:
- The patch removes the detection if the function ever touches AVX registers.
- Due to this, all call_insn RTXes have to be decorated with
CALL_NEEDS_VZEROUPPER.
- A new pre-pass is required that scans all functions in order to
detect functions with live AVX registers at exit, and at the same time
marks the functions that *do not* use AVX registers.
- Existing pass then re-scans everything to again detect functions
with live AVX registers at exit and handles vzeroupper emission.

I don't think this approach is acceptable. Maybe a LCM infrastructure
can be used to handle this case?

Uros.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]