Skip to content
Commit dd763ac7 authored by Sanjay Patel's avatar Sanjay Patel
Browse files

[SDAG] fix miscompile from merging stores of different sizes

As shown in:
https://llvm.org/PR50623
...and the similar tests here, we were not accounting for
store merging of different sizes that do not cover the
entire range of the wide value to be stored.

This is the easy fix: just make sure that all of the
original stores are the same size, so when we calculate
the wide width, it's a simple N * M check.

This still allows all of the motivating optimizations from:
D86420 / 54a5dd48
D87112 / 7a06b166

We could enhance this code to track individual bytes and
allow merging multiple sizes.
parent 206a66de
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment