Skip to content
Snippets Groups Projects
Commit 7f5adfd3 authored by Jakub Jelinek's avatar Jakub Jelinek Committed by Jakub Jelinek
Browse files

tree-ssa-propagate: Special case lhs of musttail calls in may_propagate_copy [PR118430]

This patch ensures that VRP or similar passes don't replace the uses of lhs of
[[gnu::musttail]] calls with some constant (e.g. if the call is known is known
to return a singleton value range) etc. to make it more likely that it is actually
tail callable.

2025-01-16  Jakub Jelinek  <jakub@redhat.com>

	PR tree-optimization/118430
	* tree-ssa-propagate.cc (may_propagate_copy): Return false if dest
	is lhs of an [[gnu::musttail]] call.
	(substitute_and_fold_dom_walker::before_dom_children): Formatting fix.

	* c-c++-common/musttail14.c: Expect lhs on the must tail call calls.
parent 9c4397ca
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment