357 lines
6.1 KiB
Python
357 lines
6.1 KiB
Python
import matplotlib.pyplot as plt
|
|
import numpy as np
|
|
|
|
# ypoints = np.array([19636392729, 9856229208,9445728437,5148906386])
|
|
# xpoints = np.array([5,10,15,20])
|
|
|
|
# ypoints1 = np.array([10062197042, 9873241615,12034929886,5118684853])
|
|
# xpoints1 = np.array([5,10,15,20])
|
|
|
|
ypoints = np.array([5271750211,
|
|
5947977060,
|
|
6406575235,
|
|
5511255729,
|
|
6423429240,
|
|
5094278723,
|
|
6242776302,
|
|
6297848739,
|
|
4590445845,
|
|
6764711612,
|
|
4610372742,
|
|
5903997396,
|
|
5747140551,
|
|
6300303767,
|
|
6640645385,
|
|
4818280514,
|
|
7823467298,
|
|
5828843492,
|
|
7619923263,
|
|
7891459023,
|
|
7387222066,
|
|
7941541977,
|
|
5433577677,
|
|
7362215737,
|
|
7053988636,
|
|
7387626023,
|
|
6945895832,
|
|
4915107460,
|
|
6745811484,
|
|
7802741433,
|
|
6808767570,
|
|
7717542941,
|
|
5557441777,
|
|
6274197189,
|
|
6839290749,
|
|
6583819269,
|
|
8175619486,
|
|
7374930361,
|
|
7496545906,
|
|
5787152431,
|
|
6970388902,
|
|
7150342762,
|
|
6374515148,
|
|
7086240550,
|
|
6014911926,
|
|
6805497356,
|
|
6787839300,
|
|
6029236409,
|
|
7045329429,
|
|
5463327288,
|
|
7023215119,
|
|
6305754943,
|
|
6040079901,
|
|
7642513816,
|
|
5399217904,
|
|
7615536076,
|
|
6947227611,
|
|
6886438575,
|
|
6525913645,
|
|
5704035737,
|
|
6001096710,
|
|
4595121294,
|
|
3891698114,
|
|
5754907462,
|
|
5581736391,
|
|
8438909738,
|
|
7281420759,
|
|
9120364283,
|
|
8975142455,
|
|
6194068545,
|
|
7645451782,
|
|
6244703959,
|
|
8436588830,
|
|
8530553210,
|
|
7617848374,
|
|
8172082546,
|
|
6812387244,
|
|
8703432529,
|
|
8613319990,
|
|
7501293173,
|
|
8216594940,
|
|
5673006642,
|
|
7168602771,
|
|
7846317702,
|
|
7094119540,
|
|
8854752613,
|
|
5455608081,
|
|
8407641178,
|
|
8338729110,
|
|
8119635911,
|
|
8981010962,
|
|
7495479592,
|
|
8554574662,
|
|
8404630428,
|
|
7519304345,
|
|
7136761544,
|
|
6528504686,
|
|
8236643504,
|
|
6831632676,
|
|
8347118009,
|
|
7641263754,
|
|
5707359038,
|
|
6748898177,
|
|
6066310601,
|
|
6943861727,
|
|
7098959658,
|
|
5212148705,
|
|
6824640874,
|
|
5583585529,
|
|
8003156647,
|
|
6415970122,
|
|
6830508723,
|
|
7041516118,
|
|
6892969782,
|
|
7126446374,
|
|
8238572592,
|
|
6702708346,
|
|
6612046729,
|
|
6731145590,
|
|
7182643495,
|
|
6166401716,
|
|
6391553234,
|
|
6638759846,
|
|
5539008636,
|
|
8406967616,
|
|
7660149216,
|
|
8431551979,
|
|
8269144799,
|
|
7734313131,
|
|
8403891519,
|
|
7258535328,
|
|
7776937659,
|
|
6064178686,
|
|
5770876015,
|
|
6982161319,
|
|
5235604055,
|
|
8101527192,
|
|
6046956898,
|
|
6827456214,
|
|
7874652143,
|
|
5025716700,
|
|
7506539290,
|
|
6196558003,
|
|
6656436732,
|
|
5956327575,
|
|
4626891040,
|
|
6350370528,
|
|
5249154115,
|
|
7566366652,
|
|
7035152421,
|
|
5894510533,
|
|
7071341874,
|
|
6305872895,
|
|
7188950553,
|
|
6518432441,
|
|
5956890819,
|
|
7441553601,
|
|
6285032471,
|
|
6776691911,
|
|
5916079446,
|
|
2984166525
|
|
])
|
|
|
|
xpoints = np.array([(i) for i, x in enumerate(ypoints, 1)])
|
|
|
|
ypoints1 = np.array([int(x) for x in """7320333725
|
|
8041544574
|
|
6359081713
|
|
7676718410
|
|
7408541973
|
|
8549261018
|
|
6455940864
|
|
7638044083
|
|
7852961154
|
|
8105713414
|
|
8099296359
|
|
8588846829
|
|
9264198897
|
|
7866569227
|
|
8241210929
|
|
8266772980
|
|
9025896341
|
|
8543734536
|
|
8436388827
|
|
8593700407
|
|
7449440289
|
|
8297109440
|
|
8213614706
|
|
9250000125
|
|
7852953217
|
|
8789498566
|
|
7365356677
|
|
7663656239
|
|
7930037512
|
|
7141236610
|
|
7737423168
|
|
8306296388
|
|
8693384934
|
|
7433924991
|
|
7878827892
|
|
7671595716
|
|
7150009037
|
|
8591898274
|
|
8167375582
|
|
8355489369
|
|
7173398288
|
|
8066437344
|
|
6594406377
|
|
7699310879
|
|
7502720090
|
|
7940562130
|
|
6738407130
|
|
7831934111
|
|
7551421487
|
|
8597892604
|
|
7251882911
|
|
7497411167
|
|
7623185317
|
|
6601524684
|
|
8174240923
|
|
7425424118
|
|
7689177096
|
|
5496078729
|
|
5695648325
|
|
7096458210
|
|
4812243000
|
|
8265423889
|
|
7406646505
|
|
8401794675
|
|
8029187256
|
|
8262191583
|
|
8410556911
|
|
8215142659
|
|
7977382227
|
|
8090414614
|
|
8943953292
|
|
7822463926
|
|
7959987169
|
|
7730265183
|
|
8736349787
|
|
8143049809
|
|
6640249510
|
|
7530281166
|
|
6842877170
|
|
7512789107
|
|
7638804649
|
|
7995198730
|
|
7496218179
|
|
7181518949
|
|
8254413848
|
|
8022381985
|
|
7361988882
|
|
7810130859
|
|
7417215012
|
|
7872443581
|
|
7732389294
|
|
7814055171
|
|
7463971008
|
|
8433179161
|
|
7010361542
|
|
8758722649
|
|
7834208169
|
|
7467025814
|
|
7909486359
|
|
7462899259
|
|
8890074348
|
|
8072645870
|
|
7422221759
|
|
8907995744
|
|
6612293480
|
|
7843416231
|
|
8411079708
|
|
9525606221
|
|
6937922478
|
|
7845436454
|
|
7864992534
|
|
7427672637
|
|
8619142087
|
|
8731377069
|
|
8885281498
|
|
7559808728
|
|
7173215681
|
|
7652102219
|
|
6717276768
|
|
8244303885
|
|
7151149289
|
|
7102114957
|
|
6526600396
|
|
7151648008
|
|
7526924470
|
|
8040860568
|
|
8175611289
|
|
7459798487
|
|
7145058572
|
|
6890657989
|
|
7345908520
|
|
8924306436
|
|
8931634035
|
|
8324005045
|
|
8599147593
|
|
8880835677
|
|
8165157302
|
|
7460488360
|
|
8628914421
|
|
8583302346
|
|
7934022758
|
|
7056421549
|
|
8275846606
|
|
7009386280
|
|
7495129707
|
|
7773552723
|
|
7645908705
|
|
8608406256
|
|
8712832214
|
|
7664452295
|
|
8321095578
|
|
8643168243
|
|
7250479737
|
|
7556324607
|
|
7738815689
|
|
6796106269
|
|
7213420720
|
|
7365304658
|
|
7297146598""".replace(' ',',').replace('\n','').split(",")])
|
|
|
|
# ypoints1 = np.array([1,2])
|
|
|
|
xpoints1 = np.array([(i) for i, x in enumerate(ypoints1, 1)])
|
|
|
|
plt.plot(xpoints, ypoints,label='Malloc Physically contigous with bounds')
|
|
plt.plot(xpoints1, ypoints1,label='System memory allocator')
|
|
|
|
'''
|
|
L1D_TLB
|
|
The counter counts each Memory-read operation or Memory-write operation that causes a TLB
|
|
access to at least the Level 1 data or unified TLB.
|
|
Each access to a TLB entry is counted including multiple accesses caused by single instructions
|
|
such as LDM or STM.
|
|
'''
|
|
# plt.title("Level 1 data TLB access, read \n ARM Performance counter: L1D_TLB_RD \n This counter counts each access counted by \n L1D_TLB that is a Memory-read operation. \n Kmeans C program with Cluster size 40")
|
|
|
|
plt.xlabel("time in seconds")
|
|
plt.ylabel("L1 DTLB reads")
|
|
# plt.plot(xpoints1, ypoints1)
|
|
plt.legend()
|
|
# plt.show()
|
|
|
|
plt.savefig('l1_tlb_40_dimentions.png') |