Skip to content

Commit bad955d

Browse files
yoneymeta-codesync[bot]
authored andcommitted
Add Python 3.14t HIR expectations
Summary: Add 3.14t HIR expectations for HIRBuilderStaticTest, InlinerStaticTest, InlinerEliminationStaticTest, RefcountInsertionTest, RefcountInsertionStaticTest, and SuperAccessStaticTest. Reviewed By: alexmalyshev Differential Revision: D114353233 fbshipit-source-id: f02c7c7dacb431bd8910b820e51981c68667f4a4
1 parent ca4c41a commit bad955d

6 files changed

Lines changed: 976 additions & 0 deletions

cinderx/RuntimeTests/hir_tests/hir_builder_static_test.txt

Lines changed: 243 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -490,6 +490,126 @@ fun jittestmodule:test {
490490
Branch<1>
491491
}
492492
}
493+
--- Expected 3.14t ---
494+
fun jittestmodule:test {
495+
bb 0 {
496+
v0 = LoadArg<0; "c", User[C]>
497+
v1 = LoadCurrentFunc
498+
LoadFrame
499+
Snapshot
500+
v2 = InitialYield {
501+
FrameState {
502+
CurInstrOffset 0
503+
Locals<1> v0
504+
}
505+
}
506+
Snapshot
507+
AtQuiescentState
508+
v3 = LoadEvalBreaker
509+
CondBranch<7, 6> v3
510+
}
511+
512+
bb 7 (preds 0) {
513+
Snapshot
514+
v4 = RunPeriodicTasks {
515+
FrameState {
516+
CurInstrOffset 4
517+
Locals<1> v0
518+
}
519+
}
520+
Branch<6>
521+
}
522+
523+
bb 6 (preds 0, 7) {
524+
Snapshot
525+
v5 = LoadField<ob_type@24, Type, borrowed> v0
526+
v6 = LoadField<tp_cache@368, Object, borrowed> v5
527+
v7 = LoadField<vte_state@96, Object, borrowed> v6
528+
v9 = LoadField<vte_load@104, CPtr, borrowed> v6
529+
v7 = CallInd<vte_load> v9 v7 v0 {
530+
FrameState {
531+
CurInstrOffset 8
532+
Locals<1> v0
533+
}
534+
}
535+
v8 = GetSecondOutput<CPtr> v7
536+
Snapshot
537+
v10 = CallInd<vtable invoke> v8 v7 v0 {
538+
FrameState {
539+
CurInstrOffset 12
540+
Locals<1> v0
541+
}
542+
}
543+
Snapshot
544+
v11 = CallCFunc<JitCoro_GetAwaitableIter> v10
545+
v11 = CheckExc v11 {
546+
FrameState {
547+
CurInstrOffset 16
548+
Locals<1> v0
549+
}
550+
}
551+
CondBranchCheckType<8, 10, ObjectUser[coroutine:Exact]> v11
552+
}
553+
554+
bb 10 (preds 6) {
555+
CondBranchCheckType<8, 9, ObjectUser[coroutine:Exact]> v11
556+
}
557+
558+
bb 8 (preds 6, 10) {
559+
v12 = CallCFunc<JitGen_yf> v11
560+
CondBranch<11, 9> v12
561+
}
562+
563+
bb 11 (preds 8) {
564+
RaiseStatic<RuntimeError, "coroutine is being awaited already", <<0>>> {
565+
FrameState {
566+
CurInstrOffset 16
567+
Locals<1> v0
568+
}
569+
}
570+
}
571+
572+
bb 9 (preds 8, 10) {
573+
Snapshot
574+
v13 = LoadConst<ImmortalNoneType>
575+
v14 = Assign v11
576+
v15 = Assign v13
577+
Branch<1>
578+
}
579+
580+
bb 1 (preds 2, 9) {
581+
Snapshot
582+
v16 = Send v14 v15 {
583+
FrameState {
584+
CurInstrOffset 20
585+
Locals<1> v0
586+
Stack<1> v14
587+
}
588+
}
589+
v17 = GetSecondOutput<CInt64> v16
590+
v15 = Assign v16
591+
CondBranch<3, 2> v17
592+
}
593+
594+
bb 3 (preds 1) {
595+
Snapshot
596+
Return v15
597+
}
598+
599+
bb 2 (preds 1) {
600+
Snapshot
601+
v18 = YieldValue v15 {
602+
FrameState {
603+
CurInstrOffset 24
604+
Locals<1> v0
605+
Stack<1> v14
606+
}
607+
}
608+
Snapshot
609+
v15 = Assign v18
610+
Branch<1>
611+
}
612+
}
493613
--- Test Name ---
494614
TestLoadField
495615
--- Input ---
@@ -644,6 +764,44 @@ fun jittestmodule:test {
644764
Return v4
645765
}
646766
}
767+
--- Expected 3.14t ---
768+
fun jittestmodule:test {
769+
bb 0 {
770+
v0 = LoadArg<0; "c", User[C]>
771+
v1 = LoadCurrentFunc
772+
LoadFrame
773+
v2 = TagIfDeferred v0
774+
Snapshot
775+
AtQuiescentState
776+
v3 = LoadEvalBreaker
777+
CondBranch<2, 1> v3
778+
}
779+
780+
bb 2 (preds 0) {
781+
Snapshot
782+
v4 = RunPeriodicTasks {
783+
FrameState {
784+
CurInstrOffset 0
785+
Locals<1> v2
786+
}
787+
}
788+
Branch<1>
789+
}
790+
791+
bb 1 (preds 0, 2) {
792+
Snapshot
793+
v5 = LoadField<x@32, OptObject, borrowed> v2
794+
v5 = CheckField<"x"> v5 {
795+
GuiltyReg v2
796+
FrameState {
797+
CurInstrOffset 4
798+
Locals<1> v2
799+
}
800+
}
801+
Snapshot
802+
Return v5
803+
}
804+
}
647805
--- Test Name ---
648806
TestStoreField
649807
--- Input ---
@@ -785,6 +943,41 @@ fun jittestmodule:test {
785943
Return v6
786944
}
787945
}
946+
--- Expected 3.14t ---
947+
fun jittestmodule:test {
948+
bb 0 {
949+
v0 = LoadArg<0; "c", User[C]>
950+
v1 = LoadArg<1; "x", Long>
951+
v2 = LoadCurrentFunc
952+
LoadFrame
953+
v3 = TagIfDeferred v0
954+
v4 = TagIfDeferred v1
955+
Snapshot
956+
AtQuiescentState
957+
v5 = LoadEvalBreaker
958+
CondBranch<2, 1> v5
959+
}
960+
961+
bb 2 (preds 0) {
962+
Snapshot
963+
v6 = RunPeriodicTasks {
964+
FrameState {
965+
CurInstrOffset 0
966+
Locals<2> v3 v4
967+
}
968+
}
969+
Branch<1>
970+
}
971+
972+
bb 1 (preds 0, 2) {
973+
Snapshot
974+
v7 = LoadField<x@32, OptObject, owned> v3
975+
StoreField<x@32> v3 v4 v7
976+
Snapshot
977+
v8 = LoadConst<ImmortalNoneType>
978+
Return v8
979+
}
980+
}
788981
--- Test Name ---
789982
TestFastLenList
790983
--- Input ---
@@ -3804,6 +3997,56 @@ fun jittestmodule:test {
38043997
Return v7
38053998
}
38063999
}
4000+
--- Expected 3.14t ---
4001+
fun jittestmodule:test {
4002+
bb 0 {
4003+
v0 = LoadArg<0; "self", User[A]>
4004+
v1 = LoadCurrentFunc
4005+
LoadFrame
4006+
v2 = TagIfDeferred v0
4007+
Snapshot
4008+
AtQuiescentState
4009+
v3 = LoadEvalBreaker
4010+
CondBranch<2, 1> v3
4011+
}
4012+
4013+
bb 2 (preds 0) {
4014+
Snapshot
4015+
v4 = RunPeriodicTasks {
4016+
FrameState {
4017+
CurInstrOffset 0
4018+
Locals<1> v2
4019+
}
4020+
}
4021+
Branch<1>
4022+
}
4023+
4024+
bb 1 (preds 0, 2) {
4025+
Snapshot
4026+
v5 = LoadField<_field@32, OptObject, borrowed> v2
4027+
v5 = CheckField<"_field"> v5 {
4028+
GuiltyReg v2
4029+
FrameState {
4030+
CurInstrOffset 4
4031+
Locals<1> v2
4032+
}
4033+
}
4034+
Snapshot
4035+
v5 = RefineType<List> v5
4036+
v6 = LoadConst<ImmortalLongExact[1]>
4037+
Snapshot
4038+
v7 = ListAppend v5 v6 {
4039+
FrameState {
4040+
CurInstrOffset 14
4041+
Locals<1> v2
4042+
Stack<1> v5
4043+
}
4044+
}
4045+
Snapshot
4046+
v8 = LoadConst<ImmortalNoneType>
4047+
Return v8
4048+
}
4049+
}
38074050
--- Test Name ---
38084051
CIntTypeEmitsConvertPrimitive
38094052
--- Input ---

0 commit comments

Comments
 (0)