Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rollup of 4 pull requests #41305

Merged
merged 17 commits into from
Apr 15, 2017
Merged

Rollup of 4 pull requests #41305

merged 17 commits into from
Apr 15, 2017

Conversation

Aaron1011 and others added 17 commits April 9, 2017 12:12
Previously, rustdoc's LibEmbargoVisitor unconditionally visited the
child modules of an external crate. If a module re-exported its parent
via 'pub use super::*', rustdoc would re-walk the parent, leading to
infinite recursion.

This commit makes LibEmbargoVisitor store already visited modules in an
FxHashSet, ensuring that each module is only walked once.

Fixes rust-lang#40936
Travis failures indicated the OuterVisitor#visit_item method caused a
panic. The Visitor's inner visitor actually relies on the visitor
visiting every item's NodeId. I forgot to perform that call in the
ItemGlobalAsm match arm, leading to build breakage. The fix is
simple: call visit_id(...) for ItemGlobalAsm
Windows builder croaked. This change tries to fix that by actually
calling the global_asm-defined function so the symbol doesn't get
optimized away, if that is in fact what was happening.

Additionally, we provide an empty main() for non-x86 arches.
Looks like the LinkerFlavor change introduced in rust-lang#40018 accidentally uses GCC for the WebAssembly target, causing Rust to never actually pass the post link args to emscripten. This then causes the code to be compiled as asm.js instead of WebAssembly, because the Binaryen tools never run due to the missing linker argument.
Implement global_asm!() (RFC 1548)

This is a first attempt. ~~One (potential) problem I haven't solved is how to handle multiple usages of `global_asm!` in a module/crate. It looks like `LLVMSetModuleInlineAsm` overwrites module asm, and `LLVMAppendModuleInlineAsm` is not provided in LLVM C headers 😦~~

I can provide more detail as needed, but honestly, there's not a lot going on here.

r? @eddyb

CC @Amanieu @jackpot51

Tracking issue: rust-lang#35119
Fix rustdoc infinitely recursing when an external crate reexports itself

Previously, rustdoc's LibEmbargoVisitor unconditionally visited the
child modules of an external crate. If a module re-exported its parent
via `pub use super::*`, rustdoc would re-walk the parent, leading to
infinite recursion.

This commit makes LibEmbargoVisitor store already visited modules in an
FxHashSet, ensuring that each module is only walked once.

Fixes rust-lang#40936
…eveklabnik,frewsxcv

Fix invalid associated type rendering in rustdoc

Fixes rust-lang#41036.

r? @rust-lang/docs
Compile WASM as WASM instead of asm.js

Looks like the LinkerFlavor change introduced in rust-lang#40018 accidentally uses GCC for the WebAssembly target, causing Rust to never actually pass the post link args to emscripten. This then causes the code to be compiled as asm.js instead of WebAssembly, because the Binaryen tools never run due to the missing linker argument.
@rust-highfive
Copy link
Collaborator

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @arielb1 (or someone else) soon.

If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes.

Please see the contribution instructions for more information.

@frewsxcv
Copy link
Member Author

@bors r+ p=10

@bors
Copy link
Contributor

bors commented Apr 14, 2017

📌 Commit 13dc855 has been approved by frewsxcv

@bors
Copy link
Contributor

bors commented Apr 14, 2017

⌛ Testing commit 13dc855 with merge e0529dc...

@frewsxcv frewsxcv added the S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. label Apr 14, 2017
@bors
Copy link
Contributor

bors commented Apr 14, 2017

💔 Test failed - status-appveyor

@mrhota
Copy link
Contributor

mrhota commented Apr 14, 2017

[1224/1629] Linking CXX static library lib\libLLVMMipsDisassembler.a
FAILED: lib/libLLVMMipsDisassembler.a 
cmd.exe /C "cd . && "C:\Program Files (x86)\CMake\bin\cmake.exe" -E remove lib\libLLVMMipsDisassembler.a && C:\projects\rust\mingw32\bin\ar.exe qc lib\libLLVMMipsDisassembler.a  lib/Target/Mips/Disassembler/CMakeFiles/LLVMMipsDisassembler.dir/MipsDisassembler.cpp.obj && C:\projects\rust\mingw32\bin\ranlib.exe lib\libLLVMMipsDisassembler.a && cd ."
C:\projects\rust\mingw32\bin\ar.exe: unable to rename 'lib\libLLVMMipsDisassembler.a'; reason: No such file or directory
[1225/1629] Linking CXX static library lib\libLLVMMipsAsmPrinter.a
FAILED: lib/libLLVMMipsAsmPrinter.a 
cmd.exe /C "cd . && "C:\Program Files (x86)\CMake\bin\cmake.exe" -E remove lib\libLLVMMipsAsmPrinter.a && C:\projects\rust\mingw32\bin\ar.exe qc lib\libLLVMMipsAsmPrinter.a  lib/Target/Mips/InstPrinter/CMakeFiles/LLVMMipsAsmPrinter.dir/MipsInstPrinter.cpp.obj && C:\projects\rust\mingw32\bin\ranlib.exe lib\libLLVMMipsAsmPrinter.a && cd ."
C:\projects\rust\mingw32\bin\ranlib.exe: lib\libLLVMMipsAsmPrinter.a: Malformed archive
ninja: build stopped: subcommand failed.
thread 'main' panicked at '
command did not execute successfully, got: exit code: 1
build script failed, must exit now', C:\Users\appveyor\.cargo\registry\src\github.com-1ecc6299db9ec823\cmake-0.1.22\src\lib.rs:617
note: Run with `RUST_BACKTRACE=1` for a backtrace.
	finished in 320.843
Build completed unsuccessfully in 0:07:19
Command exited with code 101

on Environment: MSYS_BITS=32, RUST_CONFIGURE_ARGS=--build=i686-pc-windows-gnu --enable-extended --enable-ninja, SCRIPT=python x.py dist, MINGW_URL=https://s3.amazonaws.com/rust-lang-ci/rust-ci-mirror, MINGW_ARCHIVE=i686-6.2.0-release-win32-dwarf-rt_v5-rev1.7z, MINGW_DIR=mingw32, DEPLOY=1

@aidanhs
Copy link
Member

aidanhs commented Apr 14, 2017

Sounds like #40546 again.

@frewsxcv
Copy link
Member Author

@bors retry

@bors
Copy link
Contributor

bors commented Apr 14, 2017

⌛ Testing commit 13dc855 with merge f0ca5d4...

bors added a commit that referenced this pull request Apr 14, 2017
Rollup of 4 pull requests

- Successful merges: #40702, #41172, #41249, #41303
- Failed merges:
@bors
Copy link
Contributor

bors commented Apr 15, 2017

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

@bors bors merged commit 13dc855 into rust-lang:master Apr 15, 2017
@Centril Centril added the rollup A PR which is a rollup label Oct 2, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
rollup A PR which is a rollup S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

10 participants