Skip to content

stdlib: enable runtime checking for COW support by default in assert builds. #32385

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 2 commits into from
Jul 3, 2020

Conversation

eeckstein
Copy link
Contributor

@eeckstein eeckstein commented Jun 15, 2020

This was blocked by an LLDB problem, which is now fixed (swiftlang/llvm-project#1333)

Also: fix a bug with array literal finalization (see commit message for details)

@eeckstein
Copy link
Contributor Author

@swift-ci test

@swift-ci
Copy link
Contributor

Build failed
Swift Test OS X Platform
Git Sha - 797ccd4170f2f04fe7a25eea6707f9e80d486ee4

@eeckstein
Copy link
Contributor Author

@swift-ci clean test macOS

@swift-ci
Copy link
Contributor

Build failed
Swift Test OS X Platform
Git Sha - 797ccd4170f2f04fe7a25eea6707f9e80d486ee4

@eeckstein eeckstein force-pushed the enable-cow-runtime-checks branch from 797ccd4 to 6e7a30e Compare June 24, 2020 14:31
@eeckstein
Copy link
Contributor Author

@swift-ci clean test

@swift-ci
Copy link
Contributor

Build failed
Swift Test OS X Platform
Git Sha - 6e7a30e15543ca4c86437dbe91e84dd4b6b71a42

@eeckstein eeckstein force-pushed the enable-cow-runtime-checks branch from 6e7a30e to d4f6a0d Compare July 1, 2020 08:49
@eeckstein
Copy link
Contributor Author

@swift-ci clean test

1 similar comment
@eeckstein
Copy link
Contributor Author

@swift-ci clean test

@swift-ci
Copy link
Contributor

swift-ci commented Jul 1, 2020

Build failed
Swift Test Linux Platform
Git Sha - d4f6a0d1fd77c866365b9736ba779886d4fb257d

eeckstein added 2 commits July 3, 2020 15:56
Array literals only need to be finalized, if the array is really allocated.
In case of zero elements, no allocation is done, but the empty-array singleton is used.
"Finalization" means to emit an end_cow_mutation instruction on the array.
As the empty-array singleton is a read-only and shared object, it's not legal to do a end_cow_mutation on it.
…builds.

This was blocked by an LLDB problem, which is now fixed (swiftlang/llvm-project#1333)
@eeckstein eeckstein force-pushed the enable-cow-runtime-checks branch from d4f6a0d to bc27356 Compare July 3, 2020 13:57
@eeckstein
Copy link
Contributor Author

@swift-ci clean test

@swift-ci
Copy link
Contributor

swift-ci commented Jul 3, 2020

Build failed
Swift Test OS X Platform
Git Sha - d4f6a0d1fd77c866365b9736ba779886d4fb257d

@swift-ci
Copy link
Contributor

swift-ci commented Jul 3, 2020

Build failed
Swift Test Linux Platform
Git Sha - d4f6a0d1fd77c866365b9736ba779886d4fb257d

@eeckstein eeckstein merged commit b85ffd3 into swiftlang:master Jul 3, 2020
@eeckstein eeckstein deleted the enable-cow-runtime-checks branch July 3, 2020 18:58
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.

2 participants