Skip to content
Commit 1646851b authored by Francis Visoiu Mistrih's avatar Francis Visoiu Mistrih
Browse files

[CGP] Look through bitcasts when duplicating returns for tail calls

The simple case of:

```
int *callee();
void *caller(void *a) {
  if (a == NULL)
    return callee();
  return a;
}
```

would generate a regular call instead of a tail call because we don't
look through the bitcast of the call to `callee` when duplicating the
return blocks.

Differential Revision: https://reviews.llvm.org/D60837

llvm-svn: 359041
parent eea9da59
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment