Skip to content

emit !align attributes on stores of operand pairs#40385

Merged
bors merged 1 commit into
rust-lang:masterfrom
arielb1:packed-again
Mar 13, 2017
Merged

emit !align attributes on stores of operand pairs#40385
bors merged 1 commit into
rust-lang:masterfrom
arielb1:packed-again

Conversation

@arielb1

@arielb1 arielb1 commented Mar 9, 2017

Copy link
Copy Markdown
Contributor

This avoids another case of missing-align UB. cc #40373

r? @eddyb

@eddyb

eddyb commented Mar 9, 2017

Copy link
Copy Markdown
Contributor

@bors r+

@bors

bors commented Mar 9, 2017

Copy link
Copy Markdown
Collaborator

📌 Commit 14e9313 has been approved by eddyb

@bors

bors commented Mar 9, 2017

Copy link
Copy Markdown
Collaborator

🔒 Merge conflict

@alexcrichton

Copy link
Copy Markdown
Member

@bors: retry

@nrc nrc assigned eddyb Mar 9, 2017
arielb1 pushed a commit to arielb1/rust that referenced this pull request Mar 9, 2017
emit !align attributes on stores of operand pairs

This avoids another case of missing-align UB. cc rust-lang#40373

r? @eddyb
alexcrichton added a commit to alexcrichton/rust that referenced this pull request Mar 10, 2017
emit !align attributes on stores of operand pairs

This avoids another case of missing-align UB. cc rust-lang#40373

r? @eddyb
alexcrichton pushed a commit to arielb1/rust that referenced this pull request Mar 10, 2017
emit !align attributes on stores of operand pairs

This avoids another case of missing-align UB. cc rust-lang#40373

r? @eddyb
Comment thread src/test/codegen/packed.rs Outdated
pub fn call_pkd(f: fn() -> Array) -> BigPacked {
// CHECK: [[ALLOCA:%[_a-z0-9]+]] = alloca %Array
// CHECK: call void %{{.*}}(%Array* noalias nocapture sret dereferenceable(32) [[ALLOCA]])
// CHECK: call void @llvm.memcpy.p0i8.p0i8.i64(i8* %{{.*}}, i8* %{{.*}}, i64 32, i32 1, i1 false)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This failed for me on emscripten / llvm 4.0, however I believe it may / will fail on other 32bit platforms as well:

/checkout/src/test/codegen/packed.rs:43:11: error: expected string not found in input
// CHECK: call void @llvm.memcpy.p0i8.p0i8.i64(i8* %{{.*}}, i8* %{{.*}}, i64 32, i32 1, i1 false)
          ^
/checkout/obj/build/x86_64-unknown-linux-gnu/test/codegen/packed.ll:34:2: note: scanning from here
 br label %bb1
 ^
/checkout/obj/build/x86_64-unknown-linux-gnu/test/codegen/packed.ll:42:2: note: possible intended match here
 call void @llvm.memcpy.p0i8.p0i8.i32(i8* %6, i8* %5, i32 32, i32 1, i1 false)
 ^

@alexcrichton

Copy link
Copy Markdown
Member

@bors: r-

(due to @TimNN's comment)

@alexcrichton

Copy link
Copy Markdown
Member

Looks like @TimNN is spot on

@arielb1 arielb1 force-pushed the packed-again branch 2 times, most recently from 4b75ee7 to 038ec50 Compare March 10, 2017 20:39
@arielb1

arielb1 commented Mar 10, 2017

Copy link
Copy Markdown
Contributor Author

@bors r=eddyb

@bors

bors commented Mar 10, 2017

Copy link
Copy Markdown
Collaborator

📌 Commit 038ec50 has been approved by eddyb

arielb1 pushed a commit to arielb1/rust that referenced this pull request Mar 10, 2017
emit !align attributes on stores of operand pairs

This avoids another case of missing-align UB. cc rust-lang#40373

r? @eddyb
arielb1 pushed a commit to arielb1/rust that referenced this pull request Mar 10, 2017
emit !align attributes on stores of operand pairs

This avoids another case of missing-align UB. cc rust-lang#40373

r? @eddyb
arielb1 pushed a commit to arielb1/rust that referenced this pull request Mar 10, 2017
emit !align attributes on stores of operand pairs

This avoids another case of missing-align UB. cc rust-lang#40373

r? @eddyb
arielb1 pushed a commit to arielb1/rust that referenced this pull request Mar 11, 2017
emit !align attributes on stores of operand pairs

This avoids another case of missing-align UB. cc rust-lang#40373

r? @eddyb
bors added a commit that referenced this pull request Mar 11, 2017
Rollup of 13 pull requests

- Successful merges: #40146, #40299, #40315, #40319, #40344, #40345, #40367, #40372, #40373, #40385, #40400, #40404, #40431
- Failed merges:
@bors

bors commented Mar 13, 2017

Copy link
Copy Markdown
Collaborator

🔒 Merge conflict

@arielb1

arielb1 commented Mar 13, 2017

Copy link
Copy Markdown
Contributor Author

@bors retry

@arielb1

arielb1 commented Mar 13, 2017

Copy link
Copy Markdown
Contributor Author

@bors r-

@arielb1

arielb1 commented Mar 13, 2017

Copy link
Copy Markdown
Contributor Author

@bors r=eddyb

@bors

bors commented Mar 13, 2017

Copy link
Copy Markdown
Collaborator

📌 Commit 32c9893 has been approved by eddyb

@bors

bors commented Mar 13, 2017

Copy link
Copy Markdown
Collaborator

⌛ Testing commit 32c9893 with merge ddc1708...

bors added a commit that referenced this pull request Mar 13, 2017
emit !align attributes on stores of operand pairs

This avoids another case of missing-align UB. cc #40373

r? @eddyb
@bors

bors commented Mar 13, 2017

Copy link
Copy Markdown
Collaborator

☀️ Test successful - status-appveyor, status-travis
Approved by: eddyb
Pushing ddc1708 to master...

@bors bors merged commit 32c9893 into rust-lang:master Mar 13, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants