Slava Pestov
0acf3ac8d9
SIL: Remove is_nonnull instruction
2017-10-13 17:38:32 -07:00
Slava Pestov
e806b6248d
SIL: Remove dynamic_method instruction
2017-10-04 03:53:16 -07:00
Andrew Trick
4db2a46cff
Add SIL instruction: open_existential_box_value.
...
This has the same semantics as open_existential_box, but returns an object value
instead of an address.
This is used in SIL opaque values mode. Attempting to reuse open_existential_box
in this mode causes SIL type inconsistencies that are too difficult to work
around. Adding this instruction allows for consistent handling of opaque values.
The original versions of several of these currently redundant instructions will
be removed once the SIL representation stabilizes.
2017-07-17 23:46:41 -07:00
Andrew Trick
f657ad2d3a
Rename *ExistentialOpaque instructions to *ExistentialValue.
...
These instructions have the same semantics as the *ExistentialAddr instructions
but operate directly on the existential value, not its address.
This is in preparation for adding ExistentialBoxValue instructions.
The previous name would cause impossible confusion with "opaque existentials"
and "opaque existential boxes".
2017-07-17 23:46:41 -07:00
Joe Shajrawi
0d0cac357a
retain_value_addr and release_value_addr SIL instructions: take as an input an address, load the value inside it and call retain_value and release_value respectively
2017-04-30 10:23:55 -07:00
Arnold Schwaighofer
b167b4475d
Add SIL and IRGen support for a ConstantStringLiteral instruction
...
This supports a utf8 or utf16 encoding.
rdar://30545013
2017-04-11 08:43:47 -07:00
Joe Shajrawi
33b0cf653f
Rename unconditional_checked_cast_opaque to unconditional_checked_cast_value
2017-03-07 18:53:52 -08:00
Joe Shajrawi
1f626304f1
Add support for conditional checked cast instruction for opaque value types + SILGen support for it
2017-03-06 16:35:27 -08:00
Joe Shajrawi
16b6cb5e1d
Support for deinit of opaque existentials: deinit_existential_opaque instruction + SILGen support
2017-02-27 14:46:43 -08:00
Joe Shajrawi
ec1e3ee20e
Add support for unconditional checked cast instruction for opaque value types + SILGen support for it
2017-02-22 16:35:46 -08:00
Joe Shajrawi
1e521c453b
Add support for Init Existentials for opaque value types
2017-02-20 16:40:02 -08:00
Joe Shajrawi
c478828de7
Support for Open Existentials that do no take an address
2017-02-09 11:25:34 -08:00
Luke Larson
74e0498015
Revert "Update master to build with Xcode 8 beta 3, OS X 10.12, iOS 10, tvOS 10, and watchOS 3 SDKs."
...
This reverts commit 62d1fa760c .
2016-07-19 15:18:17 -07:00
Mishal Shah
62d1fa760c
Update master to build with Xcode 8 beta 3, OS X 10.12, iOS 10, tvOS 10, and watchOS 3 SDKs.
2016-07-19 22:31:34 +02:00
Andrew Trick
2b732d0af5
Introduce Builtin.bindMemory and SIL bind_memory. ( #3573 )
...
Required for SE-0107: UnsafeRawPointer.
2016-07-18 13:18:03 -07:00
Erik Eckstein
c1bcb0b69d
SIL: add new instruction set_deallocating
...
It will be used by the ReleaseDevirtualizer before calling the deallocator.
So far, this is NFC.
2016-03-15 12:56:54 -07:00
Erik Eckstein
1e88689bad
vim-utils: highlight the sil call instructions in a bolder color.
...
Because often these are the most important instructions in a function.
2016-02-09 16:25:43 -08:00
Erik Eckstein
e70b38b1a5
vim-utils: add missing instruction keywords in sil syntax file
2016-02-09 16:25:43 -08:00
practicalswift
71e00fefa1
[gardening] Fix typos: "word word" (two spaces) → "word word" (one space)
2016-01-24 21:27:16 +01:00
Slava Pestov
250b6055c6
sil.vim: /* */ and // are valid comments in SIL, too
2016-01-08 17:39:23 -08:00
John McCall
5fddd4a704
Remove the autorelease_return and strong_retain_autoreleased instructions.
...
There's a buggy SIL verifier check that was previously tautological,
and it turns out that it's violated, apparently harmlessly. Since it
was already doing nothing, I've commented it out temporarily while
I figure out the right way to fix SILGen to get the invariant right.
2015-12-09 14:50:20 -08:00
Chris Willmore
c7c7388cf2
Change do-while to repeat-while.
...
Change all uses of "do { ... } while <cond>" to use "repeat" instead.
Rename DoWhileStmt to RepeatWhileStmt. Add diagnostic suggesting change
of 'do' to 'repeat' if a condition is found afterwards.
<rdar://problem/20336424> rename do/while loops to repeat/while & introduce "repeat <count> {}" loops
Swift SVN r27650
2015-04-23 22:48:31 +00:00
Joe Groff
962a87f444
SIL: Rename address-only existential instructions to '{init,deinit,open}_existential_addr'.
...
For better consistency with other address-only instruction variants, and to open the door to new exciting existential representations (such as a refcounted boxed representation for ErrorType).
Swift SVN r25902
2015-03-09 23:55:31 +00:00
Roman Levenstein
c8d180e660
Generalize the switch_int instruction into switch_value instruction, which may switch on arguments of builtin integer types or function types. The later is required for implementing a more efficient speculative devirtualizaiton implementation. Implement lowering of switch_value into LLVM code. In case of integer operands, it reuses LLVM's switch optimizations. Support for switching on function types is not yet bullet-proof and will be refined in the subsequent patches.
...
rdar://18508812
Swift SVN r23042
2014-10-31 22:55:56 +00:00
Joe Groff
3f23b82e6d
SIL: Rename SILGlobalAddr to GlobalAddr.
...
All globals are SIL globals now.
Swift SVN r22827
2014-10-18 17:08:28 +00:00
Joe Groff
ea65d1e60b
SIL: Remove the builtin_function_ref instruction.
...
Swift SVN r22797
2014-10-16 16:18:40 +00:00
Joe Groff
bb46f4bbd9
SIL: Remove the global_addr instruction.
...
It's no longer needed now that we always lower to SIL globals.
Swift SVN r22693
2014-10-12 17:19:06 +00:00
Joe Groff
782833f054
SIL: Remove the project_existential* instructions.
...
Swift SVN r22457
2014-10-02 04:06:10 +00:00
Joe Groff
3a606b9eb8
SIL: Drop the protocol_method instruction.
...
Swift SVN r22446
2014-10-01 23:35:41 +00:00
Joe Groff
be45322668
SIL: Drop the upcast_existential* instructions.
...
Swift SVN r22388
2014-09-30 16:11:54 +00:00
Joe Groff
152aa9e244
Revert "SIL: Drop the upcast_existential* instructions."
...
This reverts commit r22345.
Swift SVN r22353
2014-09-29 13:46:41 +00:00
Joe Groff
1e343fb430
SIL: Drop the upcast_existential* instructions.
...
Swift SVN r22345
2014-09-28 19:24:33 +00:00
Joe Groff
0518f2067f
Revert "SIL: Drop the upcast_existential* instructions."
...
This reverts commit r22333.
Swift SVN r22337
2014-09-28 18:41:05 +00:00
Joe Groff
727c9b5ed7
SIL: Drop the upcast_existential* instructions.
...
Swift SVN r22333
2014-09-28 16:38:13 +00:00
Joe Groff
a3126706da
SIL: Eliminate the dead 'alloc_array' insn.
...
Swift SVN r22292
2014-09-26 02:28:10 +00:00
Doug Gregor
c504086266
Revert r21707 "Remove the SIL is_nonnull instruction. It's no longer useful."
...
We want to be able to work around problems with non-failable
Objective-C initializers actually failing, which can happen when the
API audit data incorrectly marks an initializer as non-failable.
Swift SVN r21711
2014-09-04 17:26:34 +00:00
Doug Gregor
cdf94885ae
Remove the SIL is_nonnull instruction. It's no longer useful.
...
Swift SVN r21707
2014-09-04 15:56:12 +00:00
Arnold Schwaighofer
67d689dbca
Add a vim syntax file for SIL
...
Swift SVN r19343
2014-06-30 15:35:11 +00:00