* SPICE netlist
V1 VCC2 0 18
VIN1 N006 0 PULSE(0 5 0 100n 100n 0.02ms 0.04ms 70)
M1 CSW SW 0 0 NMOS
M2 CSW SW VCC VCC PMOS
V2 VCC 0 5
M5 x SW 0 0 NMOS
M6 y CSW 0 0 NMOS
R1 SW N006 1R
M3 x y N001 N001 PMOS
M4 y x N001 N001 PMOS
M7 VOUT y N005 N005 NMOS
M8 VOUT N003 N001 N001 PMOS
V3 VCC3 0 12
D1 N005 x D
M9 N003 x N005 N005 NMOS
M10 N003 VOUT N001 N001 PMOS
D2 N005 y D
R2 VCC2 N001 0.01R
R3 VCC3 N005 0.01R
.tran 0.5ms

* LTspice schematic (.asc)
Version 4
SHEET 1 1968 864
WIRE 56 -336 24 -336
WIRE 264 -336 56 -336
WIRE 504 -336 264 -336
WIRE 744 -336 504 -336
WIRE 88 -320 72 -320
WIRE 216 -320 200 -320
WIRE 456 -320 440 -320
WIRE 568 -320 552 -320
WIRE 696 -320 680 -320
WIRE 520 -256 504 -256
WIRE 88 -208 88 -320
WIRE 264 -208 264 -240
WIRE 264 -208 88 -208
WIRE 568 -208 568 -320
WIRE 744 -208 744 -240
WIRE 744 -208 568 -208
WIRE 24 -192 24 -240
WIRE 200 -192 200 -320
WIRE 200 -192 24 -192
WIRE 504 -192 504 -240
WIRE 680 -192 680 -320
WIRE 680 -192 504 -192
WIRE 744 -176 744 -208
WIRE 984 -176 744 -176
WIRE 264 -144 264 -208
WIRE 616 -144 264 -144
WIRE 504 -128 504 -192
WIRE 744 -128 744 -176
WIRE 24 -112 24 -192
WIRE 392 -112 24 -112
WIRE 392 -96 392 -112
WIRE 440 -96 392 -96
WIRE 616 -96 616 -144
WIRE 680 -96 616 -96
WIRE 440 -48 440 -96
WIRE 456 -48 440 -48
WIRE 680 -48 680 -96
WIRE 696 -48 680 -48
WIRE 24 -32 24 -112
WIRE 264 -32 264 -144
WIRE 504 -32 392 -32
WIRE 616 -32 504 -32
WIRE 744 -32 616 -32
WIRE 872 -32 744 -32
WIRE -264 80 -264 32
WIRE -312 96 -328 96
WIRE -136 176 -264 176
WIRE 216 176 -136 176
WIRE -328 224 -328 96
WIRE -24 224 -328 224
WIRE 24 224 24 -32
WIRE 264 224 264 -32
WIRE -264 240 -264 176
WIRE -536 256 -648 256
WIRE -424 256 -456 256
WIRE -328 256 -328 224
WIRE -328 256 -424 256
WIRE -24 304 -24 224
WIRE 216 304 216 176
WIRE -328 320 -328 256
WIRE -312 320 -328 320
WIRE 264 320 24 320
WIRE 504 320 264 320
WIRE 24 336 24 320
WIRE 24 336 -264 336
WIRE -264 432 -264 336
FLAG -984 -80 0
FLAG -984 -160 VCC2
FLAG -424 256 SW
FLAG -648 336 0
FLAG -136 176 CSW
FLAG -264 432 0
FLAG -984 144 0
FLAG -984 64 VCC
FLAG -264 32 VCC
FLAG 56 -416 VCC2
FLAG 24 -32 x
FLAG 264 -32 y
FLAG -968 400 0
FLAG -968 320 VCC3
FLAG 952 -32 VCC3
FLAG 984 -176 VOUT
SYMBOL voltage -984 -176 R0
SYMATTR Value 18
SYMATTR InstName V1
SYMBOL voltage -648 240 R0
SYMATTR Value PULSE(0 5 0 100n 100n 0.02ms 0.04ms 70)
SYMATTR InstName VIN1
SYMBOL nmos -312 240 R0
SYMATTR InstName M1
SYMBOL pmos -312 176 M180
SYMATTR InstName M2
SYMBOL voltage -984 48 R0
SYMATTR Value 5
SYMATTR InstName V2
SYMBOL nmos -24 224 R0
SYMATTR InstName M5
SYMBOL nmos 216 224 R0
SYMATTR InstName M6
SYMBOL res -440 240 R90
SYMATTR InstName R1
SYMATTR Value 1R
SYMBOL pmos 72 -240 R180
SYMATTR InstName M3
SYMBOL pmos 216 -240 M180
SYMATTR InstName M4
SYMBOL nmos 696 -128 R0
SYMATTR InstName M7
SYMBOL pmos 696 -240 M180
SYMATTR InstName M8
SYMBOL voltage -968 304 R0
SYMATTR Value 12
SYMATTR InstName V3
SYMBOL diode 408 -32 R180
SYMATTR InstName D1
SYMBOL nmos 456 -128 R0
SYMATTR InstName M9
SYMBOL pmos 552 -240 R180
SYMATTR InstName M10
SYMBOL diode 632 -32 R180
SYMATTR InstName D2
SYMBOL res 40 -432 R0
SYMATTR InstName R2
SYMATTR Value 0.01R
SYMBOL res 968 -48 R90
SYMATTR InstName R3
SYMATTR Value 0.01R