]> git.ipfire.org Git - thirdparty/gcc.git/commit
combine: Correct comments about combine_validate_cost
authorHans-Peter Nilsson <hp@axis.com>
Tue, 15 Apr 2025 04:08:36 +0000 (06:08 +0200)
committerHans-Peter Nilsson <hp@gcc.gnu.org>
Thu, 17 Apr 2025 03:09:36 +0000 (05:09 +0200)
commita4f81e168e02b0b1f8894070c6552b85672d4ee5
treebd5e397e479fe26a239c1094321982633aa38139
parentac31e41c584c59f8f2e381d545235a32b7c9e406
combine: Correct comments about combine_validate_cost

Fix misleading comments.  That function only determines whether
replacements cost more; it doesn't actually *validate* costs as being
cheaper.

For example, it returns true also if it for various reasons cannot
determine the costs, or if the new cost is the same, like when doing
an identity replacement.  The code has been the same since
r0-59417-g64b8935d4809f3.

* combine.cc: Correct comments about combine_validate_cost.
gcc/combine.cc