mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
SIL: Add an autorelease_value instruction.
Give us a way to formally represent autoreleases in SIL separate from autoreleased returns, allowing us to lifetime-extend inner pointer parameters the lazy way and hopefully clean up some asmname hacks in the stdlib implementation too. Swift SVN r16632
This commit is contained in:
@@ -1337,6 +1337,16 @@ public:
|
||||
: UnaryInstructionBase(loc, operand) {}
|
||||
};
|
||||
|
||||
/// Transfers ownership of a loadable value to the current autorelease pool.
|
||||
class AutoreleaseValueInst
|
||||
: public UnaryInstructionBase<ValueKind::AutoreleaseValueInst,
|
||||
SILInstruction,
|
||||
/*HasValue*/ false> {
|
||||
public:
|
||||
AutoreleaseValueInst(SILLocation loc, SILValue operand)
|
||||
: UnaryInstructionBase(loc, operand) {}
|
||||
};
|
||||
|
||||
/// TupleInst - Represents a constructed loadable tuple.
|
||||
class TupleInst : public SILInstruction {
|
||||
TailAllocatedOperandList<0> Operands;
|
||||
|
||||
Reference in New Issue
Block a user