explain.depesz.com

PostgreSQL's explain analyze made readable

Result: huxt

Settings
# exclusive inclusive rows x rows loops node
1. 1.517 47,259.988 ↓ 984.0 984 1

Sort (cost=57,876.34..57,876.35 rows=1 width=270) (actual time=47,259.916..47,259.988 rows=984 loops=1)

  • Sort Key: sq.die_id, dc.component_index
  • Sort Method: quicksort Memory: 286kB
2. 37.214 47,258.471 ↓ 984.0 984 1

Merge Join (cost=43,923.87..57,876.33 rows=1 width=270) (actual time=44,853.977..47,258.471 rows=984 loops=1)

  • Merge Cond: (des.hamiltonian_spec_id = qs.hamiltonian_spec_id)
  • Join Filter: (li.logical_index_id = qs.logical_index_id)
  • Rows Removed by Join Filter: 164820
3. 1,305.531 47,174.998 ↓ 2,350.7 21,156 1

Nested Loop (cost=43,923.59..106,319.86 rows=9 width=136) (actual time=44,853.908..47,174.998 rows=21,156 loops=1)

  • Join Filter: (des.hamiltonian_spec_id = hs.hamiltonian_spec_id)
  • Rows Removed by Join Filter: 6172850
4. 0.462 0.462 ↓ 1.2 91 1

Index Only Scan using hamiltonian_spec_pkey on hamiltonian_spec hs (cost=0.14..13.25 rows=74 width=4) (actual time=0.018..0.462 rows=91 loops=1)

  • Heap Fetches: 91
5. 1,130.543 45,869.005 ↓ 7,562.9 68,066 91

Materialize (cost=43,923.45..106,296.64 rows=9 width=132) (actual time=42.459..504.055 rows=68,066 loops=91)

6. 20.257 44,738.462 ↓ 7,562.9 68,066 1

Merge Join (cost=43,923.45..106,296.60 rows=9 width=132) (actual time=3,862.625..44,738.462 rows=68,066 loops=1)

  • Merge Cond: (d.wafer_id = w.wafer_id)
7. 187.832 44,718.002 ↓ 7,562.9 68,066 1

Nested Loop (cost=43,892.73..114,059.94 rows=9 width=131) (actual time=3,862.423..44,718.002 rows=68,066 loops=1)

  • Join Filter: (dc.component_index = li.component_index)
  • Rows Removed by Join Filter: 1342432
8. 0.938 44,363.227 ↓ 3,407.0 3,407 1

Nested Loop (cost=43,892.73..114,047.62 rows=1 width=127) (actual time=3,862.408..44,363.227 rows=3,407 loops=1)

9. 25.851 44,355.475 ↓ 3,407.0 3,407 1

Nested Loop (cost=43,892.45..114,047.31 rows=1 width=127) (actual time=3,862.398..44,355.475 rows=3,407 loops=1)

10. 28,223.049 44,322.810 ↓ 3,407.0 3,407 1

Nested Loop (cost=43,892.17..114,047.00 rows=1 width=125) (actual time=3,862.377..44,322.810 rows=3,407 loops=1)

  • Join Filter: (pc.die_id = d.die_id)
  • Rows Removed by Join Filter: 201094768
11. 44.961 44.961 ↓ 1.0 59,025 1

Index Scan using die_wafer_id_maskset_seat_id_key on die d (cost=0.29..2,850.27 rows=58,499 width=12) (actual time=0.012..44.961 rows=59,025 loops=1)

12. 14,173.566 16,054.800 ↓ 3,407.0 3,407 59,025

Materialize (cost=43,891.88..110,319.25 rows=1 width=121) (actual time=0.015..0.272 rows=3,407 loops=59,025)

13. 2.463 1,881.234 ↓ 3,407.0 3,407 1

Nested Loop (cost=43,891.88..110,319.24 rows=1 width=121) (actual time=866.776..1,881.234 rows=3,407 loops=1)

14. 2.290 1,868.550 ↓ 3,407.0 3,407 1

Nested Loop (cost=43,891.45..110,318.78 rows=1 width=107) (actual time=866.765..1,868.550 rows=3,407 loops=1)

15. 1.560 1,862.853 ↓ 3,407.0 3,407 1

Nested Loop (cost=43,891.32..110,318.62 rows=1 width=79) (actual time=866.758..1,862.853 rows=3,407 loops=1)

16. 2.809 1,854.479 ↓ 3,407.0 3,407 1

Nested Loop (cost=43,891.04..110,318.32 rows=1 width=71) (actual time=866.749..1,854.479 rows=3,407 loops=1)

17. 639.112 1,848.263 ↓ 3,407.0 3,407 1

Hash Join (cost=43,890.90..110,318.16 rows=1 width=43) (actual time=866.727..1,848.263 rows=3,407 loops=1)

  • Hash Cond: ((cm.measurement_session_id = sq.measurement_session_id) AND (cm.physical_component_id = pc.physical_component_id))
18. 349.516 349.516 ↑ 1.0 2,573,345 1

Seq Scan on component_measurements cm (cost=0.00..47,126.43 rows=2,573,443 width=15) (actual time=0.012..349.516 rows=2,573,345 loops=1)

19. 1.312 859.635 ↓ 15.4 3,407 1

Hash (cost=43,887.59..43,887.59 rows=221 width=36) (actual time=859.635..859.635 rows=3,407 loops=1)

  • Buckets: 4096 (originally 1024) Batches: 1 (originally 1) Memory Usage: 268kB
20. 1.586 858.323 ↓ 15.4 3,407 1

Nested Loop (cost=43,720.70..43,887.59 rows=221 width=36) (actual time=851.911..858.323 rows=3,407 loops=1)

21. 0.121 853.697 ↓ 42.2 380 1

Subquery Scan on sq (cost=43,720.28..43,766.38 rows=9 width=8) (actual time=851.878..853.697 rows=380 loops=1)

  • Filter: (sq.rk = 1)
  • Rows Removed by Filter: 329
22. 1.502 853.576 ↑ 2.6 709 1

Unique (cost=43,720.28..43,743.33 rows=1,844 width=24) (actual time=851.236..853.576 rows=709 loops=1)

23. 4.862 852.074 ↓ 3.5 6,367 1

Sort (cost=43,720.28..43,724.89 rows=1,844 width=24) (actual time=851.234..852.074 rows=6,367 loops=1)

  • Sort Key: ms.measurement_session_id, ms.measurement_session_start_time, d_1.die_id, (rank() OVER (?))
  • Sort Method: quicksort Memory: 690kB
24. 6.088 847.212 ↓ 3.5 6,367 1

WindowAgg (cost=43,583.37..43,620.25 rows=1,844 width=24) (actual time=840.599..847.212 rows=6,367 loops=1)

25. 2.756 841.124 ↓ 3.5 6,367 1

Sort (cost=43,583.37..43,587.98 rows=1,844 width=16) (actual time=840.588..841.124 rows=6,367 loops=1)

  • Sort Key: d_1.die_id, ms.measurement_session_start_time DESC
  • Sort Method: quicksort Memory: 491kB
26. 45.643 838.368 ↓ 3.5 6,367 1

Gather (cost=7,127.58..43,483.35 rows=1,844 width=16) (actual time=28.971..838.368 rows=6,367 loops=1)

  • Workers Planned: 2
  • Workers Launched: 2
27. 0.676 792.725 ↓ 2.8 2,122 3 / 3

Hash Join (cost=6,127.58..42,298.95 rows=768 width=16) (actual time=17.006..792.725 rows=2,122 loops=3)

  • Hash Cond: (ms.measurement_method_id = mm.measurement_method_id)
28. 1.094 792.012 ↓ 2.2 2,122 3 / 3

Hash Join (cost=6,121.16..42,289.40 rows=973 width=20) (actual time=16.909..792.012 rows=2,122 loops=3)

  • Hash Cond: (cm_1.measurement_session_id = ms.measurement_session_id)
29. 6.759 790.539 ↓ 2.2 2,122 3 / 3

Hash Join (cost=6,083.74..42,249.42 rows=973 width=8) (actual time=16.521..790.539 rows=2,122 loops=3)

  • Hash Cond: (cm_1.measurement_type_id = mt.measurement_type_id)
30. 499.402 783.770 ↓ 1.1 2,122 3 / 3

Hash Join (cost=6,082.70..42,237.86 rows=1,947 width=12) (actual time=16.501..783.770 rows=2,122 loops=3)

  • Hash Cond: (cm_1.physical_component_id = pc_1.physical_component_id)
31. 270.004 270.004 ↑ 1.3 857,782 3 / 3

Parallel Seq Scan on component_measurements cm_1 (cost=0.00..32,114.68 rows=1,072,268 width=12) (actual time=0.004..270.004 rows=857,782 loops=3)

32. 3.583 14.364 ↓ 2.8 3,407 3 / 3

Hash (cost=6,067.23..6,067.23 rows=1,238 width=8) (actual time=14.364..14.364 rows=3,407 loops=3)

  • Buckets: 4096 (originally 2048) Batches: 1 (originally 1) Memory Usage: 166kB
33. 1.629 10.781 ↓ 2.8 3,407 3 / 3

Hash Join (cost=3.00..6,067.23 rows=1,238 width=8) (actual time=1.073..10.781 rows=3,407 loops=3)

  • Hash Cond: (pc_1.physical_component_type_id = pct_1.physical_component_type_id)
34. 3.389 9.116 ↑ 1.1 4,379 3 / 3

Nested Loop (cost=0.71..6,036.46 rows=4,953 width=12) (actual time=0.126..9.116 rows=4,379 loops=3)

35. 1.052 1.052 ↑ 1.0 425 3 / 3

Index Only Scan using die_pkey on die d_1 (cost=0.29..1,086.91 rows=425 width=4) (actual time=0.107..1.052 rows=425 loops=3)

  • Index Cond: (die_id = ANY ('{6540,6576,6494,6531,6506,11908,6423,6452,6529,6569,6548,6488,6564,6496,6567,6518,6580,6583,12417,6521,6533,6497,6550,6444,6571,6527,6492,6468,6481,6554,11326,6485,6419,6501,6559,6424,6570,6446,6561,6448,6535,6541,6513,6429,6508,6472,6470,10344,6422,6504,6417,6465,6545,6454,6577,6512,6538,6434,6542,6566,6447,6442,6466,6534,6482,11663,6516,6463,6539,6507,6449,6489,6473,6451,6526,6519,6467,6511,6418,6528,6536,6441,6479,6505,6464,6437,6461,6421,6493,6582,6574,6420,6553,6428,6445,6462,6555,6459,6491,6558,6476,6514,6568,6523,6530,12213,12293,6436,6433,12313,6544,6525,6575,11746,6425,6520,6427,6443,6551,6483,6453,10447,10570,6502,6460,10347,6457,6547,6471,6474,6426,6431,6562,6478,6469,6500,6440,6515,6549,6552,6517,6455,6556,6563,6546,6573,6581,6499,6487,6475,6560,6509,6435,6432,6565,6510,6458,6430,6439,6572,6490,6579,6438,6503,11854,6480,6522,6495,6486,6532,6537,6557,10988,6484,6524,6456,12030,6477,6450,6543,6498,6578,12115,6175,6211,6129,6166,6141,12463,6058,6087,6164,6204,6183,6123,6199,6131,6202,6153,6215,6218,11953,6156,6168,6132,6185,6079,6206,6162,6127,6103,6116,6189,10694,6120,6054,6136,6194,6059,6205,6081,6196,6083,6170,6176,6148,6064,6143,6107,6105,11037,6057,6139,6052,6100,6180,6089,6212,6147,6173,6069,6177,6201,6082,6077,6101,6169,6117,12136,6151,6098,6174,6142,6084,6124,6108,6086,6161,6154,6102,6146,6053,6163,6171,6076,6114,6140,6099,6072,6096,6056,6128,6217,6209,6055,6188,6063,6080,6097,6190,6094,6126,6193,6111,6149,6203,6158,6165,11553,11495,6071,6068,11447,6179,6160,6210,12607,6060,6155,6062,6078,6186,6118,6088,10976,11407,6137,6095,11032,6092,6182,6106,6109,6061,6066,6197,6113,6104,6135,6075,6150,6184,6187,6152,6090,6191,6198,6181,6208,6216,6134,6122,6110,6195,6144,6070,6067,6200,6145,6093,6065,6074,6207,6125,6214,6073,6138,12560,6115,6157,6130,6121,6167,6172,6192,10443,6119,6159,6091,12385,6112,6085,6178,6133,6213,11647,6806,6842,6760,6797,6772,10654,6689,6718,6795,6835,6814,6754,6830,6762,6833,6784,6846,6849,11329,6787,6799,6763,6816,6710,6837,6793,6758,6734,6747,6820,12415,6751,6685,6767,6825,6690,6836,6712,6827,6714,6801,6807,6779,6695,6774,6738,6736,11621,6688,6770,6683,6731,6811,6720,6843,6778,6804,6700,6808}'::integer[]))
  • Heap Fetches: 0
36. 4.675 4.675 ↑ 2.5 10 1,275 / 3

Index Scan using ix_physical_component_die_id on physical_component pc_1 (cost=0.42..11.40 rows=25 width=12) (actual time=0.003..0.011 rows=10 loops=1,275)

  • Index Cond: (die_id = d_1.die_id)
37. 0.003 0.036 ↓ 2.0 4 3 / 3

Hash (cost=2.26..2.26 rows=2 width=4) (actual time=0.036..0.036 rows=4 loops=3)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
38. 0.014 0.033 ↓ 2.0 4 3 / 3

Hash Join (cost=1.12..2.26 rows=2 width=4) (actual time=0.030..0.033 rows=4 loops=3)

  • Hash Cond: (pct_1.designed_component_type_id = dct_1.designed_component_type_id)
39. 0.006 0.006 ↑ 1.0 10 3 / 3

Seq Scan on physical_component_type pct_1 (cost=0.00..1.10 rows=10 width=8) (actual time=0.005..0.006 rows=10 loops=3)

40. 0.003 0.013 ↑ 1.0 2 3 / 3

Hash (cost=1.10..1.10 rows=2 width=4) (actual time=0.013..0.013 rows=2 loops=3)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
41. 0.010 0.010 ↑ 1.0 2 3 / 3

Seq Scan on designed_component_type dct_1 (cost=0.00..1.10 rows=2 width=4) (actual time=0.007..0.010 rows=2 loops=3)

  • Filter: ((designed_component_type)::text = ANY ('{junction_fixed,squid_loop}'::text[]))
  • Rows Removed by Filter: 6
42. 0.003 0.010 ↑ 1.0 1 3 / 3

Hash (cost=1.02..1.02 rows=1 width=4) (actual time=0.010..0.010 rows=1 loops=3)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
43. 0.007 0.007 ↑ 1.0 1 3 / 3

Seq Scan on measurement_type mt (cost=0.00..1.02 rows=1 width=4) (actual time=0.006..0.007 rows=1 loops=3)

  • Filter: ((measurement_type)::text = 'resistance'::text)
  • Rows Removed by Filter: 6
44. 0.186 0.379 ↓ 1.0 795 3 / 3

Hash (cost=27.74..27.74 rows=774 width=16) (actual time=0.379..0.379 rows=795 loops=3)

  • Buckets: 1024 Batches: 1 Memory Usage: 49kB
45. 0.193 0.193 ↓ 1.0 795 3 / 3

Seq Scan on measurement_session ms (cost=0.00..27.74 rows=774 width=16) (actual time=0.006..0.193 rows=795 loops=3)

46. 0.008 0.037 ↑ 1.0 15 3 / 3

Hash (cost=6.24..6.24 rows=15 width=4) (actual time=0.037..0.037 rows=15 loops=3)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
47. 0.029 0.029 ↑ 1.0 15 3 / 3

Seq Scan on measurement_method mm (cost=0.00..6.24 rows=15 width=4) (actual time=0.015..0.029 rows=15 loops=3)

  • Filter: (measurement_context = 'room_temperature'::text)
  • Rows Removed by Filter: 4
48. 3.040 3.040 ↑ 2.8 9 380

Index Scan using ix_physical_component_die_id on physical_component pc (cost=0.42..13.22 rows=25 width=28) (actual time=0.003..0.008 rows=9 loops=380)

  • Index Cond: (die_id = sq.die_id)
49. 3.407 3.407 ↑ 1.0 1 3,407

Index Scan using physical_component_type_pkey on physical_component_type pct (cost=0.14..0.15 rows=1 width=36) (actual time=0.001..0.001 rows=1 loops=3,407)

  • Index Cond: (physical_component_type_id = pc.physical_component_type_id)
50. 6.814 6.814 ↑ 1.0 1 3,407

Index Scan using designed_component_pkey on designed_component dc (cost=0.29..0.30 rows=1 width=16) (actual time=0.002..0.002 rows=1 loops=3,407)

  • Index Cond: (designed_component_id = pc.designed_component_id)
51. 3.407 3.407 ↑ 1.0 1 3,407

Index Scan using designed_component_type_pkey on designed_component_type dct (cost=0.13..0.15 rows=1 width=36) (actual time=0.001..0.001 rows=1 loops=3,407)

  • Index Cond: (designed_component_type_id = dc.designed_component_type_id)
52. 10.221 10.221 ↑ 1.0 1 3,407

Index Scan using component_targets_physical_component_id_measurement_type_id_key on component_targets ct (cost=0.42..0.45 rows=1 width=26) (actual time=0.003..0.003 rows=1 loops=3,407)

  • Index Cond: (physical_component_id = cm.physical_component_id)
53. 6.814 6.814 ↑ 1.0 1 3,407

Index Scan using maskset_seat_pkey on maskset_seat mseat (cost=0.29..0.31 rows=1 width=10) (actual time=0.002..0.002 rows=1 loops=3,407)

  • Index Cond: (maskset_seat_id = d.maskset_seat_id)
54. 6.814 6.814 ↑ 1.0 1 3,407

Index Scan using design_pkey on design des (cost=0.28..0.31 rows=1 width=8) (actual time=0.002..0.002 rows=1 loops=3,407)

  • Index Cond: (design_id = dc.design_id)
55. 166.943 166.943 ↑ 1.0 414 3,407

Seq Scan on logical_index li (cost=0.00..7.14 rows=414 width=8) (actual time=0.004..0.049 rows=414 loops=3,407)

56. 0.119 0.203 ↑ 5.5 80 1

Sort (cost=30.72..31.82 rows=440 width=9) (actual time=0.194..0.203 rows=80 loops=1)

  • Sort Key: w.wafer_id
  • Sort Method: quicksort Memory: 47kB
57. 0.084 0.084 ↓ 1.1 483 1

Seq Scan on wafer w (cost=0.00..11.40 rows=440 width=9) (actual time=0.007..0.084 rows=483 loops=1)

58. 46.259 46.259 ↓ 114.3 164,877 1

Index Scan using qubit_spec_hamiltonian_spec_id_logical_index_id_key on qubit_spec qs (cost=0.28..82.96 rows=1,442 width=27) (actual time=0.024..46.259 rows=164,877 loops=1)

Planning time : 35.286 ms
Execution time : 47,261.928 ms