Bug 35803 - still can't get rid of phony compare patterns - cbranch* / cstore* patterns miss their goal
Summary: still can't get rid of phony compare patterns - cbranch* / cstore* patterns m...
Status: UNCONFIRMED
Alias: None
Product: gcc
Classification: Unclassified
Component: middle-end (show other bugs)
Version: 4.2.1
: P3 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords: internal-improvement
Depends on:
Blocks:
 
Reported: 2008-04-02 15:36 UTC by Jorn Wolfgang Rennecke
Modified: 2021-12-11 18:33 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:
Known to work:
Known to fail:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jorn Wolfgang Rennecke 2008-04-02 15:36:35 UTC
Gcc has traditionally used the concept of a compare operation that stores
a comparison result in CC0 or a register, and then can be used with arbitrary
comparison operators to compare it against zero to make a decision for
a branch, store flag, or conditional move instruction.
Since often the actual comparison instructions work differently, a number of
ports need to stash away the comparison operands when they pretend to emit
a comparison, and then emit the actual comparison later when its result is
used.
cbranch* / cstore* patterns had the promise to get rid of this bogosity,
however, they are still don;t deliver.
The only way to have a conditional move is to first perform a comparison, and
then have the the actual move depende on the comparison result.  Thus, if
the architecture has conditional move, a comparison patterns are needed, even
if the targets compare operations are ill-matched, compare patterns have to be
defined, thus disabling cbranch* / cstore* patterns.