Skip to content

[test] Fix test failure on non-x86_64 targets in failed-clang-module test case. #4043

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

Merged
merged 1 commit into from
Aug 5, 2016

Conversation

rintaro
Copy link
Member

@rintaro rintaro commented Aug 5, 2016

What's in this pull request?

Use %target-cpu instead of x86_64 in lit RUN: script
Use %target-swiftmodule-name instead of x86_64.swiftmodule in lit RUN: script

Fixes:

FAIL: Swift(iphonesimulator-i386) :: Serialization/failed-clang-module.swift (1 of 1)
******************** TEST 'Swift(iphonesimulator-i386) :: Serialization/failed-clang-module.swift' FAILED ********************
...
--
/Users/buildnode/jenkins/workspace/swift-PR-osx/buildbot_incremental/swift-macosx-x86_64/test-iphonesimulator-i386/Serialization/Output/failed-clang-module.swift.tmp/MixModA.framework/Modules/module.modulemap:3:10: error: inferred submodules require a module with an umbrella
  module * { export * }
         ^
/Users/buildnode/jenkins/workspace/swift-PR-osx/buildbot_incremental/swift-macosx-x86_64/test-iphonesimulator-i386/Serialization/Output/failed-clang-module.swift.tmp/MixModA.framework/Modules/module.modulemap:3:10: error: inferred submodules require a module with an umbrella
  module * { export * }
         ^
/Users/buildnode/jenkins/workspace/swift-PR-osx/swift/test/Serialization/Inputs/SwiftModB.swift:1:8: error: could not build Objective-C module 'MixModA'
import MixModA
       ^

Before merging this pull request to apple/swift repository:

  • Test pull request on Swift continuous integration.

Triggering Swift CI

The swift-ci is triggered by writing a comment on this PR addressed to the GitHub user @swift-ci. Different tests will run depending on the specific comment that you use. The currently available comments are:

Smoke Testing

Platform Comment
All supported platforms @swift-ci Please smoke test
All supported platforms @swift-ci Please smoke test and merge
OS X platform @swift-ci Please smoke test OS X platform
Linux platform @swift-ci Please smoke test Linux platform

A smoke test on macOS does the following:

  1. Builds the compiler incrementally.
  2. Builds the standard library only for macOS. Simulator standard libraries and
    device standard libraries are not built.
  3. lldb is not built.
  4. The test and validation-test targets are run only for macOS. The optimized
    version of these tests are not run.

A smoke test on Linux does the following:

  1. Builds the compiler incrementally.
  2. Builds the standard library incrementally.
  3. lldb is built incrementally.
  4. The swift test and validation-test targets are run. The optimized version of these
    tests are not run.
  5. lldb is tested.

Validation Testing

Platform Comment
All supported platforms @swift-ci Please test
All supported platforms @swift-ci Please test and merge
OS X platform @swift-ci Please test OS X platform
OS X platform @swift-ci Please benchmark
Linux platform @swift-ci Please test Linux platform

Lint Testing

Language Comment
Python @swift-ci Please Python lint

Note: Only members of the Apple organization can trigger swift-ci.

@rintaro
Copy link
Member Author

rintaro commented Aug 5, 2016

@swift-ci Please test

@jrose-apple
Copy link
Contributor

%target-cpu.swiftmodule isn't quite right either; armv7 and armv7k are both arm.swiftmodule. Use %target-swiftmodule-name.

@rintaro rintaro force-pushed the test-failed-clang-module-cpu branch from 62e85e2 to 0d55bdd Compare August 5, 2016 15:57
@rintaro
Copy link
Member Author

rintaro commented Aug 5, 2016

@jrose-apple Thank you! I didn't know that.

@rintaro
Copy link
Member Author

rintaro commented Aug 5, 2016

@swift-ci Please test

@rintaro
Copy link
Member Author

rintaro commented Aug 5, 2016

Linux CI bot substituted %target-swiftmodule-name to unknown.swiftmodule. Investigating

@rintaro
Copy link
Member Author

rintaro commented Aug 5, 2016

It seems, only if run_vendor == 'apple': path properly set config.target_swiftmodule_name
and, current test cases that use %target-swiftmodule-name are all XFAIL: linux or UNSUPPORTED.

I'm not sure what should I do.
@jrose-apple, @gribozavr ?

@jrose-apple
Copy link
Contributor

I think marking the test as XFAIL: linux is reasonable for now. We should get the bots back to passing.

@rintaro rintaro force-pushed the test-failed-clang-module-cpu branch from 0d55bdd to bedd93d Compare August 5, 2016 16:55
@rintaro
Copy link
Member Author

rintaro commented Aug 5, 2016

Added XFAIL: linux

@swift-ci Please test

@gribozavr
Copy link
Contributor

I think marking the test as XFAIL: linux is reasonable for now. We should get the bots back to passing.

Agreed, but it would be great to properly set %target-swiftmodule-name on Linux, too.

@jrose-apple
Copy link
Contributor

Oh, certainly. But right now we're replicating the driver logic for every architecture we care about, and doing that for Linux seems problematic.

(The reason the names don't match up, by the way, is because iOS allows armv7 and armv7s modules to coexist and interoperate.)

@akyrtzi
Copy link
Contributor

akyrtzi commented Aug 5, 2016

Thanks @rintaro !

@akyrtzi akyrtzi merged commit e809665 into swiftlang:master Aug 5, 2016
@rintaro rintaro deleted the test-failed-clang-module-cpu branch August 6, 2016 06:01
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.

4 participants