Lines Matching refs:ffix

56 static struct ptunit_result ffix_init(struct fetch_fixture *ffix)  in ffix_init()  argument
58 memset(ffix->buffer, pt_opc_bad, sizeof(ffix->buffer)); in ffix_init()
60 memset(&ffix->config, 0, sizeof(ffix->config)); in ffix_init()
61 ffix->config.size = sizeof(ffix->config); in ffix_init()
62 ffix->config.begin = ffix->buffer; in ffix_init()
63 ffix->config.end = ffix->buffer + sizeof(ffix->buffer); in ffix_init()
65 pt_encoder_init(&ffix->encoder, &ffix->config); in ffix_init()
70 static struct ptunit_result ffix_fini(struct fetch_fixture *ffix) in ffix_fini() argument
72 pt_encoder_fini(&ffix->encoder); in ffix_fini()
78 static struct ptunit_result fetch_null(struct fetch_fixture *ffix) in fetch_null() argument
83 errcode = pt_df_fetch(NULL, ffix->config.begin, &ffix->config); in fetch_null()
86 errcode = pt_df_fetch(&dfun, NULL, &ffix->config); in fetch_null()
89 errcode = pt_df_fetch(&dfun, ffix->config.begin, NULL); in fetch_null()
95 static struct ptunit_result fetch_empty(struct fetch_fixture *ffix) in fetch_empty() argument
100 errcode = pt_df_fetch(&dfun, ffix->config.end, &ffix->config); in fetch_empty()
106 static struct ptunit_result fetch_unknown(struct fetch_fixture *ffix) in fetch_unknown() argument
111 ffix->config.begin[0] = pt_opc_bad; in fetch_unknown()
113 errcode = pt_df_fetch(&dfun, ffix->config.begin, &ffix->config); in fetch_unknown()
120 static struct ptunit_result fetch_unknown_ext(struct fetch_fixture *ffix) in fetch_unknown_ext() argument
125 ffix->config.begin[0] = pt_opc_ext; in fetch_unknown_ext()
126 ffix->config.begin[1] = pt_ext_bad; in fetch_unknown_ext()
128 errcode = pt_df_fetch(&dfun, ffix->config.begin, &ffix->config); in fetch_unknown_ext()
135 static struct ptunit_result fetch_unknown_ext2(struct fetch_fixture *ffix) in fetch_unknown_ext2() argument
140 ffix->config.begin[0] = pt_opc_ext; in fetch_unknown_ext2()
141 ffix->config.begin[1] = pt_ext_ext2; in fetch_unknown_ext2()
142 ffix->config.begin[2] = pt_ext2_bad; in fetch_unknown_ext2()
144 errcode = pt_df_fetch(&dfun, ffix->config.begin, &ffix->config); in fetch_unknown_ext2()
151 static struct ptunit_result fetch_packet(struct fetch_fixture *ffix, in fetch_packet() argument
158 errcode = pt_enc_next(&ffix->encoder, packet); in fetch_packet()
161 errcode = pt_df_fetch(&dfun, ffix->config.begin, &ffix->config); in fetch_packet()
168 static struct ptunit_result fetch_type(struct fetch_fixture *ffix, in fetch_type() argument
177 ptu_test(fetch_packet, ffix, &packet, dfun); in fetch_type()
182 static struct ptunit_result fetch_tnt_8(struct fetch_fixture *ffix) in fetch_tnt_8() argument
190 ptu_test(fetch_packet, ffix, &packet, &pt_decode_tnt_8); in fetch_tnt_8()
195 static struct ptunit_result fetch_mode_exec(struct fetch_fixture *ffix) in fetch_mode_exec() argument
203 ptu_test(fetch_packet, ffix, &packet, &pt_decode_mode); in fetch_mode_exec()
208 static struct ptunit_result fetch_mode_tsx(struct fetch_fixture *ffix) in fetch_mode_tsx() argument
216 ptu_test(fetch_packet, ffix, &packet, &pt_decode_mode); in fetch_mode_tsx()
221 static struct ptunit_result fetch_exstop_ip(struct fetch_fixture *ffix) in fetch_exstop_ip() argument
229 ptu_test(fetch_packet, ffix, &packet, &pt_decode_exstop); in fetch_exstop_ip()
236 struct fetch_fixture ffix; in main() local
239 ffix.init = ffix_init; in main()
240 ffix.fini = ffix_fini; in main()
244 ptu_run_f(suite, fetch_null, ffix); in main()
245 ptu_run_f(suite, fetch_empty, ffix); in main()
247 ptu_run_f(suite, fetch_unknown, ffix); in main()
248 ptu_run_f(suite, fetch_unknown_ext, ffix); in main()
249 ptu_run_f(suite, fetch_unknown_ext2, ffix); in main()
251 ptu_run_fp(suite, fetch_type, ffix, ppt_pad, &pt_decode_pad); in main()
252 ptu_run_fp(suite, fetch_type, ffix, ppt_psb, &pt_decode_psb); in main()
253 ptu_run_fp(suite, fetch_type, ffix, ppt_tip, &pt_decode_tip); in main()
254 ptu_run_fp(suite, fetch_type, ffix, ppt_tnt_64, &pt_decode_tnt_64); in main()
255 ptu_run_fp(suite, fetch_type, ffix, ppt_tip_pge, &pt_decode_tip_pge); in main()
256 ptu_run_fp(suite, fetch_type, ffix, ppt_tip_pgd, &pt_decode_tip_pgd); in main()
257 ptu_run_fp(suite, fetch_type, ffix, ppt_fup, &pt_decode_fup); in main()
258 ptu_run_fp(suite, fetch_type, ffix, ppt_pip, &pt_decode_pip); in main()
259 ptu_run_fp(suite, fetch_type, ffix, ppt_ovf, &pt_decode_ovf); in main()
260 ptu_run_fp(suite, fetch_type, ffix, ppt_psbend, &pt_decode_psbend); in main()
261 ptu_run_fp(suite, fetch_type, ffix, ppt_tsc, &pt_decode_tsc); in main()
262 ptu_run_fp(suite, fetch_type, ffix, ppt_cbr, &pt_decode_cbr); in main()
263 ptu_run_fp(suite, fetch_type, ffix, ppt_tma, &pt_decode_tma); in main()
264 ptu_run_fp(suite, fetch_type, ffix, ppt_mtc, &pt_decode_mtc); in main()
265 ptu_run_fp(suite, fetch_type, ffix, ppt_cyc, &pt_decode_cyc); in main()
266 ptu_run_fp(suite, fetch_type, ffix, ppt_stop, &pt_decode_stop); in main()
267 ptu_run_fp(suite, fetch_type, ffix, ppt_vmcs, &pt_decode_vmcs); in main()
268 ptu_run_fp(suite, fetch_type, ffix, ppt_mnt, &pt_decode_mnt); in main()
269 ptu_run_fp(suite, fetch_type, ffix, ppt_exstop, &pt_decode_exstop); in main()
270 ptu_run_fp(suite, fetch_type, ffix, ppt_mwait, &pt_decode_mwait); in main()
271 ptu_run_fp(suite, fetch_type, ffix, ppt_pwre, &pt_decode_pwre); in main()
272 ptu_run_fp(suite, fetch_type, ffix, ppt_pwrx, &pt_decode_pwrx); in main()
273 ptu_run_fp(suite, fetch_type, ffix, ppt_ptw, &pt_decode_ptw); in main()
275 ptu_run_f(suite, fetch_tnt_8, ffix); in main()
276 ptu_run_f(suite, fetch_mode_exec, ffix); in main()
277 ptu_run_f(suite, fetch_mode_tsx, ffix); in main()
278 ptu_run_f(suite, fetch_exstop_ip, ffix); in main()