id int32 0 27.3k | func stringlengths 26 142k | target bool 2
classes | project stringclasses 2
values | commit_id stringlengths 40 40 | func_clean stringlengths 26 131k | vul_lines dict | normalized_func stringlengths 24 132k | lines listlengths 1 2.8k | label listlengths 1 2.8k | line_no listlengths 1 2.8k |
|---|---|---|---|---|---|---|---|---|---|---|
16,056 | static void qtest_irq_handler(void *opaque, int n, int level)
{
qemu_irq old_irq = *(qemu_irq *)opaque;
qemu_set_irq(old_irq, level);
if (irq_levels[n] != level) {
CharDriverState *chr = qtest_chr;
irq_levels[n] = level;
qtest_send_prefix(chr);
qtest_send(chr, "IRQ ... | true | qemu | 332cc7e9b39ddb2feacb4c71dcd18c3e5b0c3147 | static void qtest_irq_handler(void *opaque, int n, int level)
{
qemu_irq old_irq = *(qemu_irq *)opaque;
qemu_set_irq(old_irq, level);
if (irq_levels[n] != level) {
CharDriverState *chr = qtest_chr;
irq_levels[n] = level;
qtest_send_prefix(chr);
qtest_send(chr, "IRQ ... | {
"code": [
" qtest_send(chr, \"IRQ %s %d\\n\",",
" level ? \"raise\" : \"lower\", n);"
],
"line_no": [
19,
21
]
} | static void FUNC_0(void *VAR_0, int VAR_1, int VAR_2)
{
qemu_irq old_irq = *(qemu_irq *)VAR_0;
qemu_set_irq(old_irq, VAR_2);
if (irq_levels[VAR_1] != VAR_2) {
CharDriverState *chr = qtest_chr;
irq_levels[VAR_1] = VAR_2;
qtest_send_prefix(chr);
qtest_send(chr, "IRQ %... | [
"static void FUNC_0(void *VAR_0, int VAR_1, int VAR_2)\n{",
"qemu_irq old_irq = *(qemu_irq *)VAR_0;",
"qemu_set_irq(old_irq, VAR_2);",
"if (irq_levels[VAR_1] != VAR_2) {",
"CharDriverState *chr = qtest_chr;",
"irq_levels[VAR_1] = VAR_2;",
"qtest_send_prefix(chr);",
"qtest_send(chr, \"IRQ %s %d\\VAR_1\... | [
0,
0,
0,
0,
0,
0,
0,
1,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19,
21
],
[
23
],
[
25
]
] |
16,058 | void gmc1_altivec(uint8_t *dst /* align 8 */, uint8_t *src /* align1 */, int stride, int h, int x16, int y16, int rounder)
{
POWERPC_TBL_DECLARE(altivec_gmc1_num, GMC1_PERF_COND);
#ifdef ALTIVEC_USE_REFERENCE_C_CODE
const int A=(16-x16)*(16-y16);
const int B=( x16)*(16-y16);
const int C=(16-x16)*( ... | false | FFmpeg | e45a2872fafe631c14aee9f79d0963d68c4fc1fd | void gmc1_altivec(uint8_t *dst , uint8_t *src , int stride, int h, int x16, int y16, int rounder)
{
POWERPC_TBL_DECLARE(altivec_gmc1_num, GMC1_PERF_COND);
#ifdef ALTIVEC_USE_REFERENCE_C_CODE
const int A=(16-x16)*(16-y16);
const int B=( x16)*(16-y16);
const int C=(16-x16)*( y16);
const int D=(... | {
"code": [],
"line_no": []
} | void FUNC_0(uint8_t *VAR_0 , uint8_t *VAR_1 , int VAR_2, int VAR_3, int VAR_4, int VAR_5, int VAR_6)
{
POWERPC_TBL_DECLARE(altivec_gmc1_num, GMC1_PERF_COND);
#ifdef ALTIVEC_USE_REFERENCE_C_CODE
const int A=(16-VAR_4)*(16-VAR_5);
const int B=( VAR_4)*(16-VAR_5);
const int C=(16-VAR_4)*( VAR_5);
... | [
"void FUNC_0(uint8_t *VAR_0 , uint8_t *VAR_1 , int VAR_2, int VAR_3, int VAR_4, int VAR_5, int VAR_6)\n{",
"POWERPC_TBL_DECLARE(altivec_gmc1_num, GMC1_PERF_COND);",
"#ifdef ALTIVEC_USE_REFERENCE_C_CODE\nconst int A=(16-VAR_4)*(16-VAR_5);",
"const int B=( VAR_4)*(16-VAR_5);",
"const int C=(16-VAR_4)*( VA... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
[
1,
3
],
[
5
],
[
7,
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
21
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[... |
16,059 | void ff_put_h264_qpel4_mc12_msa(uint8_t *dst, const uint8_t *src,
ptrdiff_t stride)
{
avc_luma_midh_qrt_4w_msa(src - (2 * stride) - 2, stride, dst, stride, 4, 0);
}
| false | FFmpeg | e549933a270dd2cfc36f2cf9bb6b29acf3dc6d08 | void ff_put_h264_qpel4_mc12_msa(uint8_t *dst, const uint8_t *src,
ptrdiff_t stride)
{
avc_luma_midh_qrt_4w_msa(src - (2 * stride) - 2, stride, dst, stride, 4, 0);
}
| {
"code": [],
"line_no": []
} | void FUNC_0(uint8_t *VAR_0, const uint8_t *VAR_1,
ptrdiff_t VAR_2)
{
avc_luma_midh_qrt_4w_msa(VAR_1 - (2 * VAR_2) - 2, VAR_2, VAR_0, VAR_2, 4, 0);
}
| [
"void FUNC_0(uint8_t *VAR_0, const uint8_t *VAR_1,\nptrdiff_t VAR_2)\n{",
"avc_luma_midh_qrt_4w_msa(VAR_1 - (2 * VAR_2) - 2, VAR_2, VAR_0, VAR_2, 4, 0);",
"}"
] | [
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
]
] |
16,060 | enum AVCodecID avpriv_fmt_v4l2codec(uint32_t v4l2_fmt)
{
int i;
for (i = 0; avpriv_fmt_conversion_table[i].codec_id != AV_CODEC_ID_NONE; i++) {
if (avpriv_fmt_conversion_table[i].v4l2_fmt == v4l2_fmt) {
return avpriv_fmt_conversion_table[i].codec_id;
}
}
return AV... | false | FFmpeg | 931da6a5e9dd54563fe5d4d30b7bd4d0a0218c87 | enum AVCodecID avpriv_fmt_v4l2codec(uint32_t v4l2_fmt)
{
int i;
for (i = 0; avpriv_fmt_conversion_table[i].codec_id != AV_CODEC_ID_NONE; i++) {
if (avpriv_fmt_conversion_table[i].v4l2_fmt == v4l2_fmt) {
return avpriv_fmt_conversion_table[i].codec_id;
}
}
return AV... | {
"code": [],
"line_no": []
} | enum AVCodecID FUNC_0(uint32_t VAR_0)
{
int VAR_1;
for (VAR_1 = 0; avpriv_fmt_conversion_table[VAR_1].codec_id != AV_CODEC_ID_NONE; VAR_1++) {
if (avpriv_fmt_conversion_table[VAR_1].VAR_0 == VAR_0) {
return avpriv_fmt_conversion_table[VAR_1].codec_id;
}
}
return A... | [
"enum AVCodecID FUNC_0(uint32_t VAR_0)\n{",
"int VAR_1;",
"for (VAR_1 = 0; avpriv_fmt_conversion_table[VAR_1].codec_id != AV_CODEC_ID_NONE; VAR_1++) {",
"if (avpriv_fmt_conversion_table[VAR_1].VAR_0 == VAR_0) {",
"return avpriv_fmt_conversion_table[VAR_1].codec_id;",
"}",
"}",
"return AV_CODEC_ID_NONE... | [
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
21
],
[
23
]
] |
16,061 | static int read_sbr_channel_pair_element(AACContext *ac,
SpectralBandReplication *sbr,
GetBitContext *gb)
{
if (get_bits1(gb)) // bs_data_extra
skip_bits(gb, 8); // bs_reserved
if ((sbr->bs_coupling = get_bits... | false | FFmpeg | d877b88f5188fa3d71525c8d4d404daa4798e9fb | static int read_sbr_channel_pair_element(AACContext *ac,
SpectralBandReplication *sbr,
GetBitContext *gb)
{
if (get_bits1(gb))
skip_bits(gb, 8);
if ((sbr->bs_coupling = get_bits1(gb))) {
if (read_sb... | {
"code": [],
"line_no": []
} | static int FUNC_0(AACContext *VAR_0,
SpectralBandReplication *VAR_1,
GetBitContext *VAR_2)
{
if (get_bits1(VAR_2))
skip_bits(VAR_2, 8);
if ((VAR_1->bs_coupling = get_bits1(VAR_2))) {
if (read_sbr_gr... | [
"static int FUNC_0(AACContext *VAR_0,\nSpectralBandReplication *VAR_1,\nGetBitContext *VAR_2)\n{",
"if (get_bits1(VAR_2))\nskip_bits(VAR_2, 8);",
"if ((VAR_1->bs_coupling = get_bits1(VAR_2))) {",
"if (read_sbr_grid(VAR_0, VAR_1, VAR_2, &VAR_1->data[0]))\nreturn -1;",
"copy_sbr_grid(&VAR_1->data[1], &VAR_1->... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5,
7
],
[
9,
11
],
[
15
],
[
17,
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43,
45,
47
],
[
49
... |
16,062 | static av_cold int alac_encode_close(AVCodecContext *avctx)
{
AlacEncodeContext *s = avctx->priv_data;
ff_lpc_end(&s->lpc_ctx);
av_freep(&avctx->extradata);
avctx->extradata_size = 0;
av_freep(&avctx->coded_frame);
return 0;
}
| false | FFmpeg | d6604b29ef544793479d7fb4e05ef6622bb3e534 | static av_cold int alac_encode_close(AVCodecContext *avctx)
{
AlacEncodeContext *s = avctx->priv_data;
ff_lpc_end(&s->lpc_ctx);
av_freep(&avctx->extradata);
avctx->extradata_size = 0;
av_freep(&avctx->coded_frame);
return 0;
}
| {
"code": [],
"line_no": []
} | static av_cold int FUNC_0(AVCodecContext *avctx)
{
AlacEncodeContext *s = avctx->priv_data;
ff_lpc_end(&s->lpc_ctx);
av_freep(&avctx->extradata);
avctx->extradata_size = 0;
av_freep(&avctx->coded_frame);
return 0;
}
| [
"static av_cold int FUNC_0(AVCodecContext *avctx)\n{",
"AlacEncodeContext *s = avctx->priv_data;",
"ff_lpc_end(&s->lpc_ctx);",
"av_freep(&avctx->extradata);",
"avctx->extradata_size = 0;",
"av_freep(&avctx->coded_frame);",
"return 0;",
"}"
] | [
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
]
] |
16,064 | av_cold int ff_mpv_encode_init(AVCodecContext *avctx)
{
MpegEncContext *s = avctx->priv_data;
AVCPBProperties *cpb_props;
int i, ret, format_supported;
mpv_encode_defaults(s);
switch (avctx->codec_id) {
case AV_CODEC_ID_MPEG2VIDEO:
if (avctx->pix_fmt != AV_PIX_FMT_YUV420P &&
... | false | FFmpeg | 0e6c8532215790bbe560a9eea4f3cc82bb55cf92 | av_cold int ff_mpv_encode_init(AVCodecContext *avctx)
{
MpegEncContext *s = avctx->priv_data;
AVCPBProperties *cpb_props;
int i, ret, format_supported;
mpv_encode_defaults(s);
switch (avctx->codec_id) {
case AV_CODEC_ID_MPEG2VIDEO:
if (avctx->pix_fmt != AV_PIX_FMT_YUV420P &&
... | {
"code": [],
"line_no": []
} | av_cold int FUNC_0(AVCodecContext *avctx)
{
MpegEncContext *s = avctx->priv_data;
AVCPBProperties *cpb_props;
int VAR_0, VAR_1, VAR_2;
mpv_encode_defaults(s);
switch (avctx->codec_id) {
case AV_CODEC_ID_MPEG2VIDEO:
if (avctx->pix_fmt != AV_PIX_FMT_YUV420P &&
avct... | [
"av_cold int FUNC_0(AVCodecContext *avctx)\n{",
"MpegEncContext *s = avctx->priv_data;",
"AVCPBProperties *cpb_props;",
"int VAR_0, VAR_1, VAR_2;",
"mpv_encode_defaults(s);",
"switch (avctx->codec_id) {",
"case AV_CODEC_ID_MPEG2VIDEO:\nif (avctx->pix_fmt != AV_PIX_FMT_YUV420P &&\navctx->pix_fmt != AV_PI... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
13
],
[
17
],
[
19,
21,
23
],
[
25,
27
],
[
29
],
[
31
],
[
33
],
[
35,
37
],
[
41,
43,
45,
47,
49,
51
],
[
55,
57,
59,
61
... |
16,065 | static inline void gen_op_eval_fbg(TCGv dst, TCGv src,
unsigned int fcc_offset)
{
gen_mov_reg_FCC0(dst, src, fcc_offset);
tcg_gen_xori_tl(dst, dst, 0x1);
gen_mov_reg_FCC1(cpu_tmp0, src, fcc_offset);
tcg_gen_and_tl(dst, dst, cpu_tmp0);
}
| false | qemu | de9e9d9f17a36ff76c1a02a5348835e5e0a081b0 | static inline void gen_op_eval_fbg(TCGv dst, TCGv src,
unsigned int fcc_offset)
{
gen_mov_reg_FCC0(dst, src, fcc_offset);
tcg_gen_xori_tl(dst, dst, 0x1);
gen_mov_reg_FCC1(cpu_tmp0, src, fcc_offset);
tcg_gen_and_tl(dst, dst, cpu_tmp0);
}
| {
"code": [],
"line_no": []
} | static inline void FUNC_0(TCGv VAR_0, TCGv VAR_1,
unsigned int VAR_2)
{
gen_mov_reg_FCC0(VAR_0, VAR_1, VAR_2);
tcg_gen_xori_tl(VAR_0, VAR_0, 0x1);
gen_mov_reg_FCC1(cpu_tmp0, VAR_1, VAR_2);
tcg_gen_and_tl(VAR_0, VAR_0, cpu_tmp0);
}
| [
"static inline void FUNC_0(TCGv VAR_0, TCGv VAR_1,\nunsigned int VAR_2)\n{",
"gen_mov_reg_FCC0(VAR_0, VAR_1, VAR_2);",
"tcg_gen_xori_tl(VAR_0, VAR_0, 0x1);",
"gen_mov_reg_FCC1(cpu_tmp0, VAR_1, VAR_2);",
"tcg_gen_and_tl(VAR_0, VAR_0, cpu_tmp0);",
"}"
] | [
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
]
] |
16,066 | static void disas_simd_across_lanes(DisasContext *s, uint32_t insn)
{
unsupported_encoding(s, insn);
}
| false | qemu | 4a0ff1ce73a9e06ecb655019820229de74244432 | static void disas_simd_across_lanes(DisasContext *s, uint32_t insn)
{
unsupported_encoding(s, insn);
}
| {
"code": [],
"line_no": []
} | static void FUNC_0(DisasContext *VAR_0, uint32_t VAR_1)
{
unsupported_encoding(VAR_0, VAR_1);
}
| [
"static void FUNC_0(DisasContext *VAR_0, uint32_t VAR_1)\n{",
"unsupported_encoding(VAR_0, VAR_1);",
"}"
] | [
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
]
] |
16,067 | static int readv_f(int argc, char **argv)
{
struct timeval t1, t2;
int Cflag = 0, qflag = 0, vflag = 0;
int c, cnt;
char *buf;
int64_t offset;
/* Some compilers get confused and warn if this is not initialized. */
int total = 0;
int nr_iov;
QEMUIOVector qiov;
int patt... | false | qemu | 031380d8770d2df6c386e4aeabd412007d3ebd54 | static int readv_f(int argc, char **argv)
{
struct timeval t1, t2;
int Cflag = 0, qflag = 0, vflag = 0;
int c, cnt;
char *buf;
int64_t offset;
int total = 0;
int nr_iov;
QEMUIOVector qiov;
int pattern = 0;
int Pflag = 0;
while ((c = getopt(argc, argv, "CP:... | {
"code": [],
"line_no": []
} | static int FUNC_0(int VAR_0, char **VAR_1)
{
struct timeval VAR_2, VAR_3;
int VAR_4 = 0, VAR_5 = 0, VAR_6 = 0;
int VAR_7, VAR_8;
char *VAR_9;
int64_t offset;
int VAR_10 = 0;
int VAR_11;
QEMUIOVector qiov;
int VAR_12 = 0;
int VAR_13 = 0;
while ((VAR_7 = get... | [
"static int FUNC_0(int VAR_0, char **VAR_1)\n{",
"struct timeval VAR_2, VAR_3;",
"int VAR_4 = 0, VAR_5 = 0, VAR_6 = 0;",
"int VAR_7, VAR_8;",
"char *VAR_9;",
"int64_t offset;",
"int VAR_10 = 0;",
"int VAR_11;",
"QEMUIOVector qiov;",
"int VAR_12 = 0;",
"int VAR_13 = 0;",
"while ((VAR_7 = getopt... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
29
],
[
31
],
[
33,
35
],
[
37
],
[
39,
41
],
[
43
],
[
45
],
[
47
... |
16,069 | void nbd_client_put(NBDClient *client)
{
if (--client->refcount == 0) {
/* The last reference should be dropped by client->close,
* which is called by nbd_client_close.
*/
assert(client->closing);
nbd_unset_handlers(client);
close(client->sock);
c... | false | qemu | f53a829bb9ef14be800556cbc02d8b20fc1050a7 | void nbd_client_put(NBDClient *client)
{
if (--client->refcount == 0) {
assert(client->closing);
nbd_unset_handlers(client);
close(client->sock);
client->sock = -1;
if (client->exp) {
QTAILQ_REMOVE(&client->exp->clients, client, next);
... | {
"code": [],
"line_no": []
} | void FUNC_0(NBDClient *VAR_0)
{
if (--VAR_0->refcount == 0) {
assert(VAR_0->closing);
nbd_unset_handlers(VAR_0);
close(VAR_0->sock);
VAR_0->sock = -1;
if (VAR_0->exp) {
QTAILQ_REMOVE(&VAR_0->exp->clients, VAR_0, next);
nbd_expo... | [
"void FUNC_0(NBDClient *VAR_0)\n{",
"if (--VAR_0->refcount == 0) {",
"assert(VAR_0->closing);",
"nbd_unset_handlers(VAR_0);",
"close(VAR_0->sock);",
"VAR_0->sock = -1;",
"if (VAR_0->exp) {",
"QTAILQ_REMOVE(&VAR_0->exp->clients, VAR_0, next);",
"nbd_export_put(VAR_0->exp);",
"}",
"g_free(VAR_0);"... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
13
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
]
] |
16,070 | static void arm11mpcore_initfn(Object *obj)
{
ARMCPU *cpu = ARM_CPU(obj);
set_feature(&cpu->env, ARM_FEATURE_V6K);
set_feature(&cpu->env, ARM_FEATURE_VFP);
set_feature(&cpu->env, ARM_FEATURE_VAPA);
cpu->midr = ARM_CPUID_ARM11MPCORE;
cpu->reset_fpsid = 0x410120b4;
cpu->mvfr0 = 0x11111... | false | qemu | 200bf596b96820186883953de9bda26cac8e6bd7 | static void arm11mpcore_initfn(Object *obj)
{
ARMCPU *cpu = ARM_CPU(obj);
set_feature(&cpu->env, ARM_FEATURE_V6K);
set_feature(&cpu->env, ARM_FEATURE_VFP);
set_feature(&cpu->env, ARM_FEATURE_VAPA);
cpu->midr = ARM_CPUID_ARM11MPCORE;
cpu->reset_fpsid = 0x410120b4;
cpu->mvfr0 = 0x11111... | {
"code": [],
"line_no": []
} | static void FUNC_0(Object *VAR_0)
{
ARMCPU *cpu = ARM_CPU(VAR_0);
set_feature(&cpu->env, ARM_FEATURE_V6K);
set_feature(&cpu->env, ARM_FEATURE_VFP);
set_feature(&cpu->env, ARM_FEATURE_VAPA);
cpu->midr = ARM_CPUID_ARM11MPCORE;
cpu->reset_fpsid = 0x410120b4;
cpu->mvfr0 = 0x11111111;
... | [
"static void FUNC_0(Object *VAR_0)\n{",
"ARMCPU *cpu = ARM_CPU(VAR_0);",
"set_feature(&cpu->env, ARM_FEATURE_V6K);",
"set_feature(&cpu->env, ARM_FEATURE_VFP);",
"set_feature(&cpu->env, ARM_FEATURE_VAPA);",
"cpu->midr = ARM_CPUID_ARM11MPCORE;",
"cpu->reset_fpsid = 0x410120b4;",
"cpu->mvfr0 = 0x11111111... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
... |
16,071 | void pci_device_hot_add(Monitor *mon, const QDict *qdict)
{
PCIDevice *dev = NULL;
const char *pci_addr = qdict_get_str(qdict, "pci_addr");
const char *type = qdict_get_str(qdict, "type");
const char *opts = qdict_get_try_str(qdict, "opts");
/* strip legacy tag */
if (!strncmp(pci_addr,... | false | qemu | 79ca616f291124d166ca173e512c4ace1c2fe8b2 | void pci_device_hot_add(Monitor *mon, const QDict *qdict)
{
PCIDevice *dev = NULL;
const char *pci_addr = qdict_get_str(qdict, "pci_addr");
const char *type = qdict_get_str(qdict, "type");
const char *opts = qdict_get_try_str(qdict, "opts");
if (!strncmp(pci_addr, "pci_addr=", 9)) {
... | {
"code": [],
"line_no": []
} | void FUNC_0(Monitor *VAR_0, const QDict *VAR_1)
{
PCIDevice *dev = NULL;
const char *VAR_2 = qdict_get_str(VAR_1, "VAR_2");
const char *VAR_3 = qdict_get_str(VAR_1, "VAR_3");
const char *VAR_4 = qdict_get_try_str(VAR_1, "VAR_4");
if (!strncmp(VAR_2, "VAR_2=", 9)) {
VAR_2 += 9;... | [
"void FUNC_0(Monitor *VAR_0, const QDict *VAR_1)\n{",
"PCIDevice *dev = NULL;",
"const char *VAR_2 = qdict_get_str(VAR_1, \"VAR_2\");",
"const char *VAR_3 = qdict_get_str(VAR_1, \"VAR_3\");",
"const char *VAR_4 = qdict_get_try_str(VAR_1, \"VAR_4\");",
"if (!strncmp(VAR_2, \"VAR_2=\", 9)) {",
"VAR_2 += 9... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
17
],
[
19
],
[
21
],
[
25
],
[
27
],
[
29
],
[
33,
35
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49
],
[
51
],
[... |
16,072 | float32 helper_fsqrts(CPUSPARCState *env, float32 src)
{
float32 ret;
clear_float_exceptions(env);
ret = float32_sqrt(src, &env->fp_status);
check_ieee_exceptions(env);
return ret;
}
| false | qemu | 7385aed20db5d83979f683b9d0048674411e963c | float32 helper_fsqrts(CPUSPARCState *env, float32 src)
{
float32 ret;
clear_float_exceptions(env);
ret = float32_sqrt(src, &env->fp_status);
check_ieee_exceptions(env);
return ret;
}
| {
"code": [],
"line_no": []
} | float32 FUNC_0(CPUSPARCState *env, float32 src)
{
float32 ret;
clear_float_exceptions(env);
ret = float32_sqrt(src, &env->fp_status);
check_ieee_exceptions(env);
return ret;
}
| [
"float32 FUNC_0(CPUSPARCState *env, float32 src)\n{",
"float32 ret;",
"clear_float_exceptions(env);",
"ret = float32_sqrt(src, &env->fp_status);",
"check_ieee_exceptions(env);",
"return ret;",
"}"
] | [
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
]
] |
16,073 | ser_read(void *opaque, target_phys_addr_t addr, unsigned int size)
{
struct etrax_serial *s = opaque;
D(CPUCRISState *env = s->env);
uint32_t r = 0;
addr >>= 2;
switch (addr)
{
case R_STAT_DIN:
r = s->rx_fifo[(s->rx_fifo_pos - s->rx_fifo_len) & 15];
if... | false | qemu | a8170e5e97ad17ca169c64ba87ae2f53850dab4c | ser_read(void *opaque, target_phys_addr_t addr, unsigned int size)
{
struct etrax_serial *s = opaque;
D(CPUCRISState *env = s->env);
uint32_t r = 0;
addr >>= 2;
switch (addr)
{
case R_STAT_DIN:
r = s->rx_fifo[(s->rx_fifo_pos - s->rx_fifo_len) & 15];
if... | {
"code": [],
"line_no": []
} | FUNC_0(void *VAR_0, target_phys_addr_t VAR_1, unsigned int VAR_2)
{
struct etrax_serial *VAR_3 = VAR_0;
D(CPUCRISState *env = VAR_3->env);
uint32_t r = 0;
VAR_1 >>= 2;
switch (VAR_1)
{
case R_STAT_DIN:
r = VAR_3->rx_fifo[(VAR_3->rx_fifo_pos - VAR_3->rx_fifo_len) & ... | [
"FUNC_0(void *VAR_0, target_phys_addr_t VAR_1, unsigned int VAR_2)\n{",
"struct etrax_serial *VAR_3 = VAR_0;",
"D(CPUCRISState *env = VAR_3->env);",
"uint32_t r = 0;",
"VAR_1 >>= 2;",
"switch (VAR_1)\n{",
"case R_STAT_DIN:\nr = VAR_3->rx_fifo[(VAR_3->rx_fifo_pos - VAR_3->rx_fifo_len) & 15];",
"if (VAR... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
13
],
[
15,
17
],
[
19,
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35,
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[... |
16,075 | static void vfio_probe_nvidia_bar0_88000_quirk(VFIODevice *vdev, int nr)
{
PCIDevice *pdev = &vdev->pdev;
VFIOQuirk *quirk;
if (!vdev->has_vga || nr != 0 ||
pci_get_word(pdev->config + PCI_VENDOR_ID) != PCI_VENDOR_ID_NVIDIA) {
return;
}
quirk = g_malloc0(sizeof(*quirk));
... | false | qemu | 96eeeba0db38b856eb2cae0e4a2a620d8d65771a | static void vfio_probe_nvidia_bar0_88000_quirk(VFIODevice *vdev, int nr)
{
PCIDevice *pdev = &vdev->pdev;
VFIOQuirk *quirk;
if (!vdev->has_vga || nr != 0 ||
pci_get_word(pdev->config + PCI_VENDOR_ID) != PCI_VENDOR_ID_NVIDIA) {
return;
}
quirk = g_malloc0(sizeof(*quirk));
... | {
"code": [],
"line_no": []
} | static void FUNC_0(VFIODevice *VAR_0, int VAR_1)
{
PCIDevice *pdev = &VAR_0->pdev;
VFIOQuirk *quirk;
if (!VAR_0->has_vga || VAR_1 != 0 ||
pci_get_word(pdev->config + PCI_VENDOR_ID) != PCI_VENDOR_ID_NVIDIA) {
return;
}
quirk = g_malloc0(sizeof(*quirk));
quirk->VAR_0 =... | [
"static void FUNC_0(VFIODevice *VAR_0, int VAR_1)\n{",
"PCIDevice *pdev = &VAR_0->pdev;",
"VFIOQuirk *quirk;",
"if (!VAR_0->has_vga || VAR_1 != 0 ||\npci_get_word(pdev->config + PCI_VENDOR_ID) != PCI_VENDOR_ID_NVIDIA) {",
"return;",
"}",
"quirk = g_malloc0(sizeof(*quirk));",
"quirk->VAR_0 = VAR_0;",
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11,
13
],
[
15
],
[
17
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
35,
37,
39
],
[
41,
43,
45
],
[
49
],
[
53,
55,
57
],
... |
16,077 | static subpage_t *subpage_init(target_phys_addr_t base)
{
subpage_t *mmio;
mmio = g_malloc0(sizeof(subpage_t));
mmio->base = base;
memory_region_init_io(&mmio->iomem, &subpage_ops, mmio,
"subpage", TARGET_PAGE_SIZE);
mmio->iomem.subpage = true;
#if defined(DEBUG... | false | qemu | a8170e5e97ad17ca169c64ba87ae2f53850dab4c | static subpage_t *subpage_init(target_phys_addr_t base)
{
subpage_t *mmio;
mmio = g_malloc0(sizeof(subpage_t));
mmio->base = base;
memory_region_init_io(&mmio->iomem, &subpage_ops, mmio,
"subpage", TARGET_PAGE_SIZE);
mmio->iomem.subpage = true;
#if defined(DEBUG... | {
"code": [],
"line_no": []
} | static subpage_t *FUNC_0(target_phys_addr_t base)
{
subpage_t *mmio;
mmio = g_malloc0(sizeof(subpage_t));
mmio->base = base;
memory_region_init_io(&mmio->iomem, &subpage_ops, mmio,
"subpage", TARGET_PAGE_SIZE);
mmio->iomem.subpage = true;
#if defined(DEBUG_SUBPA... | [
"static subpage_t *FUNC_0(target_phys_addr_t base)\n{",
"subpage_t *mmio;",
"mmio = g_malloc0(sizeof(subpage_t));",
"mmio->base = base;",
"memory_region_init_io(&mmio->iomem, &subpage_ops, mmio,\n\"subpage\", TARGET_PAGE_SIZE);",
"mmio->iomem.subpage = true;",
"#if defined(DEBUG_SUBPAGE)\nprintf(\"%s: %... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
13
],
[
15,
17
],
[
19
],
[
21,
23,
25
],
[
27,
29
],
[
33
],
[
35
]
] |
16,078 | static abi_long do_bind(int sockfd, abi_ulong target_addr,
socklen_t addrlen)
{
void *addr;
abi_long ret;
if (addrlen < 0)
return -TARGET_EINVAL;
addr = alloca(addrlen+1);
ret = target_to_host_sockaddr(addr, target_addr, addrlen);
if (ret)
... | false | qemu | 3872425343439555e543cd606c44a79dbcc168d4 | static abi_long do_bind(int sockfd, abi_ulong target_addr,
socklen_t addrlen)
{
void *addr;
abi_long ret;
if (addrlen < 0)
return -TARGET_EINVAL;
addr = alloca(addrlen+1);
ret = target_to_host_sockaddr(addr, target_addr, addrlen);
if (ret)
... | {
"code": [],
"line_no": []
} | static abi_long FUNC_0(int sockfd, abi_ulong target_addr,
socklen_t addrlen)
{
void *VAR_0;
abi_long ret;
if (addrlen < 0)
return -TARGET_EINVAL;
VAR_0 = alloca(addrlen+1);
ret = target_to_host_sockaddr(VAR_0, target_addr, addrlen);
if (ret)
... | [
"static abi_long FUNC_0(int sockfd, abi_ulong target_addr,\nsocklen_t addrlen)\n{",
"void *VAR_0;",
"abi_long ret;",
"if (addrlen < 0)\nreturn -TARGET_EINVAL;",
"VAR_0 = alloca(addrlen+1);",
"ret = target_to_host_sockaddr(VAR_0, target_addr, addrlen);",
"if (ret)\nreturn ret;",
"return get_errno(bind(... | [
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
13,
15
],
[
19
],
[
23
],
[
25,
27
],
[
31
],
[
33
]
] |
16,079 | int net_client_init(Monitor *mon, const char *device, const char *p)
{
static const char * const fd_params[] = {
"vlan", "name", "fd", NULL
};
char buf[1024];
int vlan_id, ret;
VLANState *vlan;
char *name = NULL;
vlan_id = 0;
if (get_param_value(buf, sizeof(buf), "vla... | false | qemu | 0df0ff6de70393680cea81ad696d9d74b75f88da | int net_client_init(Monitor *mon, const char *device, const char *p)
{
static const char * const fd_params[] = {
"vlan", "name", "fd", NULL
};
char buf[1024];
int vlan_id, ret;
VLANState *vlan;
char *name = NULL;
vlan_id = 0;
if (get_param_value(buf, sizeof(buf), "vla... | {
"code": [],
"line_no": []
} | int FUNC_0(Monitor *VAR_0, const char *VAR_1, const char *VAR_2)
{
static const char * const VAR_3[] = {
"vlan", "VAR_7", "VAR_16", NULL
};
char VAR_4[1024];
int VAR_5, VAR_6;
VLANState *vlan;
char *VAR_7 = NULL;
VAR_5 = 0;
if (get_param_value(VAR_4, sizeof(VAR_4), "v... | [
"int FUNC_0(Monitor *VAR_0, const char *VAR_1, const char *VAR_2)\n{",
"static const char * const VAR_3[] = {",
"\"vlan\", \"VAR_7\", \"VAR_16\", NULL\n};",
"char VAR_4[1024];",
"int VAR_5, VAR_6;",
"VLANState *vlan;",
"char *VAR_7 = NULL;",
"VAR_5 = 0;",
"if (get_param_value(VAR_4, sizeof(VAR_4), \... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
[
1,
3
],
[
5
],
[
7,
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43,
45
],
[
47
... |
16,080 | void tcg_target_qemu_prologue (TCGContext *s)
{
int i, frame_size;
frame_size = 0
+ 8 /* back chain */
+ 8 /* CR */
+ 8 /* LR */
+ 8 /* compiler doubleword */
+ 8 ... | false | qemu | a69abbe0b3428a13c8225e1bd5ea3c938a9319af | void tcg_target_qemu_prologue (TCGContext *s)
{
int i, frame_size;
frame_size = 0
+ 8
+ 8
+ 8
+ 8
+ 8
+ 8
+ TCG_STATIC... | {
"code": [],
"line_no": []
} | void FUNC_0 (TCGContext *VAR_0)
{
int VAR_1, VAR_2;
VAR_2 = 0
+ 8
+ 8
+ 8
+ 8
+ 8
+ 8
+ TCG_STATIC_CALL_ARGS_SIZE
... | [
"void FUNC_0 (TCGContext *VAR_0)\n{",
"int VAR_1, VAR_2;",
"VAR_2 = 0\n+ 8\n+ 8\n+ 8\n+ 8\n+ 8\n+ 8\n+ TCG_STATIC_CALL_ARGS_SIZE\n+ ARRAY_SIZE (tcg_target_callee_save_regs) * 8\n;",
"VAR_2 = (VAR_2 + 15) & ~15;",
"tcg_out32 (VAR_0, MFSPR | RT (0) | LR);",
"tcg_out32 (VAR_0, STDU | RS (1) | RA (1) | (-VAR_... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9,
11,
13,
15,
17,
19,
21,
23,
25,
27
],
[
29
],
[
33
],
[
35
],
[
37
],
[
39,
41,
43,
45,
47,
49
],
[
51
],
[
53
],
[
57
],
[
59
],
[
61... |
16,081 | static void pxa2xx_pm_write(void *opaque, hwaddr addr,
uint64_t value, unsigned size)
{
PXA2xxState *s = (PXA2xxState *) opaque;
switch (addr) {
case PMCR:
/* Clear the write-one-to-clear bits... */
s->pm_regs[addr >> 2] &= ~(value & 0x2a);
/* ..... | false | qemu | a89f364ae8740dfc31b321eed9ee454e996dc3c1 | static void pxa2xx_pm_write(void *opaque, hwaddr addr,
uint64_t value, unsigned size)
{
PXA2xxState *s = (PXA2xxState *) opaque;
switch (addr) {
case PMCR:
s->pm_regs[addr >> 2] &= ~(value & 0x2a);
s->pm_regs[addr >> 2] &= ~0x15;
... | {
"code": [],
"line_no": []
} | static void FUNC_0(void *VAR_0, hwaddr VAR_1,
uint64_t VAR_2, unsigned VAR_3)
{
PXA2xxState *s = (PXA2xxState *) VAR_0;
switch (VAR_1) {
case PMCR:
s->pm_regs[VAR_1 >> 2] &= ~(VAR_2 & 0x2a);
s->pm_regs[VAR_1 >> 2] &= ~0x15;
s-... | [
"static void FUNC_0(void *VAR_0, hwaddr VAR_1,\nuint64_t VAR_2, unsigned VAR_3)\n{",
"PXA2xxState *s = (PXA2xxState *) VAR_0;",
"switch (VAR_1) {",
"case PMCR:\ns->pm_regs[VAR_1 >> 2] &= ~(VAR_2 & 0x2a);",
"s->pm_regs[VAR_1 >> 2] &= ~0x15;",
"s->pm_regs[VAR_1 >> 2] |= VAR_2 & 0x15;",
"break;",
"case P... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
11
],
[
13,
17
],
[
21
],
[
23
],
[
25
],
[
29,
31,
33,
35
],
[
37
],
[
41,
43
],
[
45
],
[
47
],
[
49
],
[
53
],
[
55
],
[
57
],
[
59... |
16,082 | static unsigned int dec_rfe_etc(DisasContext *dc)
{
cris_cc_mask(dc, 0);
if (dc->op2 == 15) /* ignore halt. */
return 2;
switch (dc->op2 & 7) {
case 2:
/* rfe. */
DIS(fprintf(logfile, "rfe\n"));
cris_evaluate_flags(dc);
tcg_gen_helper_0_0(helper_rfe);
dc->is_jmp = DISAS_UPDATE;
... | false | qemu | a7812ae412311d7d47f8aa85656faadac9d64b56 | static unsigned int dec_rfe_etc(DisasContext *dc)
{
cris_cc_mask(dc, 0);
if (dc->op2 == 15)
return 2;
switch (dc->op2 & 7) {
case 2:
DIS(fprintf(logfile, "rfe\n"));
cris_evaluate_flags(dc);
tcg_gen_helper_0_0(helper_rfe);
dc->is_jmp = DISAS_UPDATE;
break;
case 5:
D... | {
"code": [],
"line_no": []
} | static unsigned int FUNC_0(DisasContext *VAR_0)
{
cris_cc_mask(VAR_0, 0);
if (VAR_0->op2 == 15)
return 2;
switch (VAR_0->op2 & 7) {
case 2:
DIS(fprintf(logfile, "rfe\n"));
cris_evaluate_flags(VAR_0);
tcg_gen_helper_0_0(helper_rfe);
VAR_0->is_jmp = DISAS_UPDATE;
break;
case ... | [
"static unsigned int FUNC_0(DisasContext *VAR_0)\n{",
"cris_cc_mask(VAR_0, 0);",
"if (VAR_0->op2 == 15)\nreturn 2;",
"switch (VAR_0->op2 & 7) {",
"case 2:\nDIS(fprintf(logfile, \"rfe\\n\"));",
"cris_evaluate_flags(VAR_0);",
"tcg_gen_helper_0_0(helper_rfe);",
"VAR_0->is_jmp = DISAS_UPDATE;",
"break;"... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9,
11
],
[
15
],
[
17,
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31,
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45,
47
],
[
49
],
[
53
],
[
59... |
16,084 | ram_addr_t get_current_ram_size(void)
{
MemoryDeviceInfoList *info_list = NULL;
MemoryDeviceInfoList **prev = &info_list;
MemoryDeviceInfoList *info;
ram_addr_t size = ram_size;
qmp_pc_dimm_device_list(qdev_get_machine(), &prev);
for (info = info_list; info; info = info->next) {
... | false | qemu | 1fd5d4fea4ba686705fd377c7cffc0f0c9f83f93 | ram_addr_t get_current_ram_size(void)
{
MemoryDeviceInfoList *info_list = NULL;
MemoryDeviceInfoList **prev = &info_list;
MemoryDeviceInfoList *info;
ram_addr_t size = ram_size;
qmp_pc_dimm_device_list(qdev_get_machine(), &prev);
for (info = info_list; info; info = info->next) {
... | {
"code": [],
"line_no": []
} | ram_addr_t FUNC_0(void)
{
MemoryDeviceInfoList *info_list = NULL;
MemoryDeviceInfoList **prev = &info_list;
MemoryDeviceInfoList *info;
ram_addr_t size = ram_size;
qmp_pc_dimm_device_list(qdev_get_machine(), &prev);
for (info = info_list; info; info = info->next) {
MemoryDevice... | [
"ram_addr_t FUNC_0(void)\n{",
"MemoryDeviceInfoList *info_list = NULL;",
"MemoryDeviceInfoList **prev = &info_list;",
"MemoryDeviceInfoList *info;",
"ram_addr_t size = ram_size;",
"qmp_pc_dimm_device_list(qdev_get_machine(), &prev);",
"for (info = info_list; info; info = info->next) {",
"MemoryDeviceI... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
15
],
[
17
],
[
19
],
[
23
],
[
25
],
[
27,
29
],
[
31
],
[
33,
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
47
],
[
49
... |
16,085 | static int ipvideo_decode_frame(AVCodecContext *avctx,
void *data, int *got_frame,
AVPacket *avpkt)
{
const uint8_t *buf = avpkt->data;
int buf_size = avpkt->size;
IpvideoContext *s = avctx->priv_data;
AVFrame *frame = data;
int... | false | FFmpeg | 19f6fd199e46c5a56f09a768ece4246b48bd86dd | static int ipvideo_decode_frame(AVCodecContext *avctx,
void *data, int *got_frame,
AVPacket *avpkt)
{
const uint8_t *buf = avpkt->data;
int buf_size = avpkt->size;
IpvideoContext *s = avctx->priv_data;
AVFrame *frame = data;
int... | {
"code": [],
"line_no": []
} | static int FUNC_0(AVCodecContext *VAR_0,
void *VAR_1, int *VAR_2,
AVPacket *VAR_3)
{
const uint8_t *VAR_4 = VAR_3->VAR_1;
int VAR_5 = VAR_3->VAR_10;
IpvideoContext *s = VAR_0->priv_data;
AVFrame *frame = VAR_1;
int VAR_6;
i... | [
"static int FUNC_0(AVCodecContext *VAR_0,\nvoid *VAR_1, int *VAR_2,\nAVPacket *VAR_3)\n{",
"const uint8_t *VAR_4 = VAR_3->VAR_1;",
"int VAR_5 = VAR_3->VAR_10;",
"IpvideoContext *s = VAR_0->priv_data;",
"AVFrame *frame = VAR_1;",
"int VAR_6;",
"int VAR_7;",
"int VAR_8;",
"int VAR_9;",
"if (av_packe... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5,
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
27
],
[
29
],
[
31
],
[
33
],
[
37,
39
],
[
43
],
[
45
],
[
47
],
[
49
],
[... |
16,087 | static ssize_t fd_put_buffer(void *opaque, const void *data, size_t size)
{
FdMigrationState *s = opaque;
ssize_t ret;
do {
ret = write(s->fd, data, size);
} while (ret == -1 && errno == EINTR);
if (ret == -1)
ret = -errno;
if (ret == -EAGAIN)
qemu_set_fd_... | false | qemu | 17e909738da65d315d462839a05628580b96f8c1 | static ssize_t fd_put_buffer(void *opaque, const void *data, size_t size)
{
FdMigrationState *s = opaque;
ssize_t ret;
do {
ret = write(s->fd, data, size);
} while (ret == -1 && errno == EINTR);
if (ret == -1)
ret = -errno;
if (ret == -EAGAIN)
qemu_set_fd_... | {
"code": [],
"line_no": []
} | static ssize_t FUNC_0(void *opaque, const void *data, size_t size)
{
FdMigrationState *s = opaque;
ssize_t ret;
do {
ret = write(s->fd, data, size);
} while (ret == -1 && errno == EINTR);
if (ret == -1)
ret = -errno;
if (ret == -EAGAIN)
qemu_set_fd_handler... | [
"static ssize_t FUNC_0(void *opaque, const void *data, size_t size)\n{",
"FdMigrationState *s = opaque;",
"ssize_t ret;",
"do {",
"ret = write(s->fd, data, size);",
"} while (ret == -1 && errno == EINTR);",
"if (ret == -1)\nret = -errno;",
"if (ret == -EAGAIN)\nqemu_set_fd_handler2(s->fd, NULL, NULL, ... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
13
],
[
15
],
[
19,
21
],
[
25,
27
],
[
31
],
[
33
]
] |
16,088 | static void tap_send(void *opaque)
{
TAPState *s = opaque;
int size;
int packets = 0;
while (qemu_can_send_packet(&s->nc)) {
uint8_t *buf = s->buf;
size = tap_read_packet(s->fd, s->buf, sizeof(s->buf));
if (size <= 0) {
break;
}
if (s-... | false | qemu | a90a7425cf592a3afeff3eaf32f543b83050ee5c | static void tap_send(void *opaque)
{
TAPState *s = opaque;
int size;
int packets = 0;
while (qemu_can_send_packet(&s->nc)) {
uint8_t *buf = s->buf;
size = tap_read_packet(s->fd, s->buf, sizeof(s->buf));
if (size <= 0) {
break;
}
if (s-... | {
"code": [],
"line_no": []
} | static void FUNC_0(void *VAR_0)
{
TAPState *s = VAR_0;
int VAR_1;
int VAR_2 = 0;
while (qemu_can_send_packet(&s->nc)) {
uint8_t *buf = s->buf;
VAR_1 = tap_read_packet(s->fd, s->buf, sizeof(s->buf));
if (VAR_1 <= 0) {
break;
}
if (s->ho... | [
"static void FUNC_0(void *VAR_0)\n{",
"TAPState *s = VAR_0;",
"int VAR_1;",
"int VAR_2 = 0;",
"while (qemu_can_send_packet(&s->nc)) {",
"uint8_t *buf = s->buf;",
"VAR_1 = tap_read_packet(s->fd, s->buf, sizeof(s->buf));",
"if (VAR_1 <= 0) {",
"break;",
"}",
"if (s->host_vnet_hdr_len && !s->using_... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
19
],
[
21
],
[
23
],
[
25
],
[
29
],
[
31
],
[
33
],
[
35
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49
... |
16,091 | pflash_t *pflash_cfi01_register(target_phys_addr_t base, ram_addr_t off,
BlockDriverState *bs, uint32_t sector_len,
int nb_blocs, int width,
uint16_t id0, uint16_t id1,
uint16_t id2, uint1... | false | qemu | d0e7605ee0d91c3737052127a79199ddab3ff653 | pflash_t *pflash_cfi01_register(target_phys_addr_t base, ram_addr_t off,
BlockDriverState *bs, uint32_t sector_len,
int nb_blocs, int width,
uint16_t id0, uint16_t id1,
uint16_t id2, uint1... | {
"code": [],
"line_no": []
} | pflash_t *FUNC_0(target_phys_addr_t base, ram_addr_t off,
BlockDriverState *bs, uint32_t sector_len,
int nb_blocs, int width,
uint16_t id0, uint16_t id1,
uint16_t id2, uint16_t id3)
{
... | [
"pflash_t *FUNC_0(target_phys_addr_t base, ram_addr_t off,\nBlockDriverState *bs, uint32_t sector_len,\nint nb_blocs, int width,\nuint16_t id0, uint16_t id1,\nuint16_t id2, uint16_t id3)\n{",
"pflash_t *pfl;",
"target_phys_addr_t total_len;",
"total_len = sector_len * nb_blocs;",
"#if 0\nif (total_len != (8... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
[
1,
3,
5,
7,
9,
11
],
[
13
],
[
15
],
[
19
],
[
25,
27,
29,
31
],
[
33,
37
],
[
43
],
[
45,
47
],
[
49
],
[
51,
53
],
[
57
],
[
59
],
[
63
],
[
65
],
[
67,... |
16,092 | static void sigp_set_prefix(CPUState *cs, run_on_cpu_data arg)
{
S390CPU *cpu = S390_CPU(cs);
SigpInfo *si = arg.host_ptr;
uint32_t addr = si->param & 0x7fffe000u;
cpu_synchronize_state(cs);
if (!address_space_access_valid(&address_space_memory, addr,
s... | false | qemu | 74b4c74d5efb0a489bdf0acc5b5d0197167e7649 | static void sigp_set_prefix(CPUState *cs, run_on_cpu_data arg)
{
S390CPU *cpu = S390_CPU(cs);
SigpInfo *si = arg.host_ptr;
uint32_t addr = si->param & 0x7fffe000u;
cpu_synchronize_state(cs);
if (!address_space_access_valid(&address_space_memory, addr,
s... | {
"code": [],
"line_no": []
} | static void FUNC_0(CPUState *VAR_0, run_on_cpu_data VAR_1)
{
S390CPU *cpu = S390_CPU(VAR_0);
SigpInfo *si = VAR_1.host_ptr;
uint32_t addr = si->param & 0x7fffe000u;
cpu_synchronize_state(VAR_0);
if (!address_space_access_valid(&address_space_memory, addr,
... | [
"static void FUNC_0(CPUState *VAR_0, run_on_cpu_data VAR_1)\n{",
"S390CPU *cpu = S390_CPU(VAR_0);",
"SigpInfo *si = VAR_1.host_ptr;",
"uint32_t addr = si->param & 0x7fffe000u;",
"cpu_synchronize_state(VAR_0);",
"if (!address_space_access_valid(&address_space_memory, addr,\nsizeof(struct LowCore), false)) ... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
13
],
[
17,
19
],
[
21
],
[
23
],
[
25
],
[
31
],
[
33
],
[
35
],
[
37
],
[
41
],
[
43
],
[
45
],
[
47
]
] |
16,094 | static void memory_map_init(void)
{
system_memory = qemu_malloc(sizeof(*system_memory));
memory_region_init(system_memory, "system", UINT64_MAX);
set_system_memory_map(system_memory);
}
| true | qemu | 8417cebfda193c7f9ca70be5e308eaa92cf84b94 | static void memory_map_init(void)
{
system_memory = qemu_malloc(sizeof(*system_memory));
memory_region_init(system_memory, "system", UINT64_MAX);
set_system_memory_map(system_memory);
}
| {
"code": [
" memory_region_init(system_memory, \"system\", UINT64_MAX);"
],
"line_no": [
7
]
} | static void FUNC_0(void)
{
system_memory = qemu_malloc(sizeof(*system_memory));
memory_region_init(system_memory, "system", UINT64_MAX);
set_system_memory_map(system_memory);
}
| [
"static void FUNC_0(void)\n{",
"system_memory = qemu_malloc(sizeof(*system_memory));",
"memory_region_init(system_memory, \"system\", UINT64_MAX);",
"set_system_memory_map(system_memory);",
"}"
] | [
0,
0,
1,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
]
] |
16,095 | static void qxl_realize_primary(PCIDevice *dev, Error **errp)
{
PCIQXLDevice *qxl = PCI_QXL(dev);
VGACommonState *vga = &qxl->vga;
Error *local_err = NULL;
qxl->id = 0;
qxl_init_ramsize(qxl);
vga->vbe_size = qxl->vgamem_size;
vga->vram_size_mb = qxl->vga.vram_size >> 20;
vga_c... | true | qemu | 47025a0193f1f910300adfa443305ccf8482ef87 | static void qxl_realize_primary(PCIDevice *dev, Error **errp)
{
PCIQXLDevice *qxl = PCI_QXL(dev);
VGACommonState *vga = &qxl->vga;
Error *local_err = NULL;
qxl->id = 0;
qxl_init_ramsize(qxl);
vga->vbe_size = qxl->vgamem_size;
vga->vram_size_mb = qxl->vga.vram_size >> 20;
vga_c... | {
"code": [
" qemu_spice_display_init_common(&qxl->ssd);"
],
"line_no": [
39
]
} | static void FUNC_0(PCIDevice *VAR_0, Error **VAR_1)
{
PCIQXLDevice *qxl = PCI_QXL(VAR_0);
VGACommonState *vga = &qxl->vga;
Error *local_err = NULL;
qxl->id = 0;
qxl_init_ramsize(qxl);
vga->vbe_size = qxl->vgamem_size;
vga->vram_size_mb = qxl->vga.vram_size >> 20;
vga_common_in... | [
"static void FUNC_0(PCIDevice *VAR_0, Error **VAR_1)\n{",
"PCIQXLDevice *qxl = PCI_QXL(VAR_0);",
"VGACommonState *vga = &qxl->vga;",
"Error *local_err = NULL;",
"qxl->id = 0;",
"qxl_init_ramsize(qxl);",
"vga->vbe_size = qxl->vgamem_size;",
"vga->vram_size_mb = qxl->vga.vram_size >> 20;",
"vga_common... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23,
25
],
[
27,
29
],
[
31
],
[
33
],
[
37
],
[
39
],
[
43
],
[
45
],
[
47
],
[
49
... |
16,096 | const char *path(const char *name)
{
/* Only do absolute paths: quick and dirty, but should mostly be OK.
Could do relative by tracking cwd. */
if (!base || name[0] != '/')
return name;
return follow_path(base, name) ?: name;
}
| true | qemu | a516e72d60803cac3b81b3330db55983b080d8da | const char *path(const char *name)
{
if (!base || name[0] != '/')
return name;
return follow_path(base, name) ?: name;
}
| {
"code": [
" if (!base || name[0] != '/')"
],
"line_no": [
9
]
} | const char *FUNC_0(const char *VAR_0)
{
if (!base || VAR_0[0] != '/')
return VAR_0;
return follow_path(base, VAR_0) ?: VAR_0;
}
| [
"const char *FUNC_0(const char *VAR_0)\n{",
"if (!base || VAR_0[0] != '/')\nreturn VAR_0;",
"return follow_path(base, VAR_0) ?: VAR_0;",
"}"
] | [
0,
1,
0,
0
] | [
[
1,
3
],
[
9,
11
],
[
15
],
[
17
]
] |
16,097 | static int aac_decode_er_frame(AVCodecContext *avctx, void *data,
int *got_frame_ptr, GetBitContext *gb)
{
AACContext *ac = avctx->priv_data;
const MPEG4AudioConfig *const m4ac = &ac->oc[1].m4ac;
ChannelElement *che;
int err, i;
int samples = m4ac->frame_length_... | true | FFmpeg | fee7c42bf45f72d457fafaee536f054ce59e4ec5 | static int aac_decode_er_frame(AVCodecContext *avctx, void *data,
int *got_frame_ptr, GetBitContext *gb)
{
AACContext *ac = avctx->priv_data;
const MPEG4AudioConfig *const m4ac = &ac->oc[1].m4ac;
ChannelElement *che;
int err, i;
int samples = m4ac->frame_length_... | {
"code": [
" spectral_to_sample(ac);",
" spectral_to_sample(ac);"
],
"line_no": [
115,
115
]
} | static int FUNC_0(AVCodecContext *VAR_0, void *VAR_1,
int *VAR_2, GetBitContext *VAR_3)
{
AACContext *ac = VAR_0->priv_data;
const MPEG4AudioConfig *const VAR_4 = &ac->oc[1].VAR_4;
ChannelElement *che;
int VAR_5, VAR_6;
int VAR_7 = VAR_4->frame_length_short ? 96... | [
"static int FUNC_0(AVCodecContext *VAR_0, void *VAR_1,\nint *VAR_2, GetBitContext *VAR_3)\n{",
"AACContext *ac = VAR_0->priv_data;",
"const MPEG4AudioConfig *const VAR_4 = &ac->oc[1].VAR_4;",
"ChannelElement *che;",
"int VAR_5, VAR_6;",
"int VAR_7 = VAR_4->frame_length_short ? 960 : 1024;",
"int VAR_8 =... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
23,
25
],
[
29
],
[
33,
35
],
[
43
],
[
47
],
[
51
],
[
53,
55
],
[
57
],
[
59
],
[
61
... |
16,098 | static void versatile_init(MachineState *machine, int board_id)
{
ObjectClass *cpu_oc;
Object *cpuobj;
ARMCPU *cpu;
MemoryRegion *sysmem = get_system_memory();
MemoryRegion *ram = g_new(MemoryRegion, 1);
qemu_irq pic[32];
qemu_irq sic[32];
DeviceState *dev, *sysctl;
SysBusDevice *bus... | true | qemu | 5c8c2aafcf02986a998cf71aa47692fff176ad69 | static void versatile_init(MachineState *machine, int board_id)
{
ObjectClass *cpu_oc;
Object *cpuobj;
ARMCPU *cpu;
MemoryRegion *sysmem = get_system_memory();
MemoryRegion *ram = g_new(MemoryRegion, 1);
qemu_irq pic[32];
qemu_irq sic[32];
DeviceState *dev, *sysctl;
SysBusDevice *bus... | {
"code": [],
"line_no": []
} | static void FUNC_0(MachineState *VAR_0, int VAR_1)
{
ObjectClass *cpu_oc;
Object *cpuobj;
ARMCPU *cpu;
MemoryRegion *sysmem = get_system_memory();
MemoryRegion *ram = g_new(MemoryRegion, 1);
qemu_irq pic[32];
qemu_irq sic[32];
DeviceState *dev, *sysctl;
SysBusDevice *busdev;
Devi... | [
"static void FUNC_0(MachineState *VAR_0, int VAR_1)\n{",
"ObjectClass *cpu_oc;",
"Object *cpuobj;",
"ARMCPU *cpu;",
"MemoryRegion *sysmem = get_system_memory();",
"MemoryRegion *ram = g_new(MemoryRegion, 1);",
"qemu_irq pic[32];",
"qemu_irq sic[32];",
"DeviceState *dev, *sysctl;",
"SysBusDevice *b... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
[
1,
2
],
[
3
],
[
4
],
[
5
],
[
6
],
[
7
],
[
8
],
[
9
],
[
10
],
[
11
],
[
12
],
[
13
],
[
14
],
[
15
],
[
16
],
[
17
],
[
18
],
[
19
],
[
20
],
[
21
],... |
16,099 | int css_do_ssch(SubchDev *sch, ORB *orb)
{
SCSW *s = &sch->curr_status.scsw;
PMCW *p = &sch->curr_status.pmcw;
int ret;
if (~(p->flags) & (PMCW_FLAGS_MASK_DNV | PMCW_FLAGS_MASK_ENA)) {
ret = -ENODEV;
goto out;
}
if (s->ctrl & SCSW_STCTL_STATUS_PEND) {
ret = ... | true | qemu | 66dc50f7057b9a0191f54e55764412202306858d | int css_do_ssch(SubchDev *sch, ORB *orb)
{
SCSW *s = &sch->curr_status.scsw;
PMCW *p = &sch->curr_status.pmcw;
int ret;
if (~(p->flags) & (PMCW_FLAGS_MASK_DNV | PMCW_FLAGS_MASK_ENA)) {
ret = -ENODEV;
goto out;
}
if (s->ctrl & SCSW_STCTL_STATUS_PEND) {
ret = ... | {
"code": [
" int ret;",
" ret = -ENODEV;",
" return ret;",
" return ret;",
"int css_do_ssch(SubchDev *sch, ORB *orb)",
" int ret;",
" ret = -ENODEV;",
" goto out;",
" ret = -EINPROGRESS;",
" goto out;",
" ret = -EBUSY;"... | int FUNC_0(SubchDev *VAR_0, ORB *VAR_1)
{
SCSW *s = &VAR_0->curr_status.scsw;
PMCW *p = &VAR_0->curr_status.pmcw;
int VAR_2;
if (~(p->flags) & (PMCW_FLAGS_MASK_DNV | PMCW_FLAGS_MASK_ENA)) {
VAR_2 = -ENODEV;
goto out;
}
if (s->ctrl & SCSW_STCTL_STATUS_PEND) {
... | [
"int FUNC_0(SubchDev *VAR_0, ORB *VAR_1)\n{",
"SCSW *s = &VAR_0->curr_status.scsw;",
"PMCW *p = &VAR_0->curr_status.pmcw;",
"int VAR_2;",
"if (~(p->flags) & (PMCW_FLAGS_MASK_DNV | PMCW_FLAGS_MASK_ENA)) {",
"VAR_2 = -ENODEV;",
"goto out;",
"}",
"if (s->ctrl & SCSW_STCTL_STATUS_PEND) {",
"VAR_2 = -E... | [
1,
0,
0,
1,
0,
1,
1,
0,
0,
1,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
1,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
17
],
[
19
],
[
23
],
[
25
],
[
27
],
[
29
],
[
33,
35,
37
],
[
39
],
[
41
],
[
43
],
[
49
],
[
51
],
[
53
... |
16,100 | static int mxf_edit_unit_absolute_offset(MXFContext *mxf, MXFIndexTable *index_table, int64_t edit_unit, int64_t *edit_unit_out, int64_t *offset_out, int nag)
{
int i;
int offset_temp = 0;
for (i = 0; i < index_table->nb_segments; i++) {
MXFIndexTableSegment *s = index_table->segments[i];
... | true | FFmpeg | b720915be103cc8b062405bf9f7765ce3ad679d1 | static int mxf_edit_unit_absolute_offset(MXFContext *mxf, MXFIndexTable *index_table, int64_t edit_unit, int64_t *edit_unit_out, int64_t *offset_out, int nag)
{
int i;
int offset_temp = 0;
for (i = 0; i < index_table->nb_segments; i++) {
MXFIndexTableSegment *s = index_table->segments[i];
... | {
"code": [
" int offset_temp = 0;"
],
"line_no": [
7
]
} | static int FUNC_0(MXFContext *VAR_0, MXFIndexTable *VAR_1, int64_t VAR_2, int64_t *VAR_3, int64_t *VAR_4, int VAR_5)
{
int VAR_6;
int VAR_7 = 0;
for (VAR_6 = 0; VAR_6 < VAR_1->nb_segments; VAR_6++) {
MXFIndexTableSegment *s = VAR_1->segments[VAR_6];
VAR_2 = FFMAX(VAR_2, s->index_st... | [
"static int FUNC_0(MXFContext *VAR_0, MXFIndexTable *VAR_1, int64_t VAR_2, int64_t *VAR_3, int64_t *VAR_4, int VAR_5)\n{",
"int VAR_6;",
"int VAR_7 = 0;",
"for (VAR_6 = 0; VAR_6 < VAR_1->nb_segments; VAR_6++) {",
"MXFIndexTableSegment *s = VAR_1->segments[VAR_6];",
"VAR_2 = FFMAX(VAR_2, s->index_start_pos... | [
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
13
],
[
17
],
[
21
],
[
23
],
[
27,
29
],
[
31
],
[
33,
35
],
[
39
],
[
41,
43
],
[
45
],
[
47
],
[
51
],
[
53
],
[
55,
57... |
16,101 | QEMUPutLEDEntry *qemu_add_led_event_handler(QEMUPutLEDEvent *func,
void *opaque)
{
QEMUPutLEDEntry *s;
s = g_malloc0(sizeof(QEMUPutLEDEntry));
s->put_led = func;
s->opaque = opaque;
QTAILQ_INSERT_TAIL(&led_handlers, s, next);
return s;
}
| true | qemu | fedf0d35aafc4f1f1e5f6dbc80cb23ae1ae49f0b | QEMUPutLEDEntry *qemu_add_led_event_handler(QEMUPutLEDEvent *func,
void *opaque)
{
QEMUPutLEDEntry *s;
s = g_malloc0(sizeof(QEMUPutLEDEntry));
s->put_led = func;
s->opaque = opaque;
QTAILQ_INSERT_TAIL(&led_handlers, s, next);
return s;
}
| {
"code": [
" s = g_malloc0(sizeof(QEMUPutLEDEntry));"
],
"line_no": [
11
]
} | QEMUPutLEDEntry *FUNC_0(QEMUPutLEDEvent *func,
void *opaque)
{
QEMUPutLEDEntry *s;
s = g_malloc0(sizeof(QEMUPutLEDEntry));
s->put_led = func;
s->opaque = opaque;
QTAILQ_INSERT_TAIL(&led_handlers, s, next);
return s;
}
| [
"QEMUPutLEDEntry *FUNC_0(QEMUPutLEDEvent *func,\nvoid *opaque)\n{",
"QEMUPutLEDEntry *s;",
"s = g_malloc0(sizeof(QEMUPutLEDEntry));",
"s->put_led = func;",
"s->opaque = opaque;",
"QTAILQ_INSERT_TAIL(&led_handlers, s, next);",
"return s;",
"}"
] | [
0,
0,
1,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
11
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
]
] |
16,102 | static int mp3_read_probe(AVProbeData *p)
{
int max_frames, first_frames;
int fsize, frames, sample_rate;
uint32_t header;
uint8_t *buf, *buf2, *end;
AVCodecContext avctx;
if(id3v2_match(p->buf))
return AVPROBE_SCORE_MAX/2+1; // this must be less than mpeg-ps because some retar... | true | FFmpeg | ea7599ba8bbbf38ce958e5cdc621bd85b420826b | static int mp3_read_probe(AVProbeData *p)
{
int max_frames, first_frames;
int fsize, frames, sample_rate;
uint32_t header;
uint8_t *buf, *buf2, *end;
AVCodecContext avctx;
if(id3v2_match(p->buf))
return AVPROBE_SCORE_MAX/2+1;
max_frames = 0;
buf = p->buf;
end ... | {
"code": [
" int max_frames, first_frames;"
],
"line_no": [
5
]
} | static int FUNC_0(AVProbeData *VAR_0)
{
int VAR_1, VAR_2;
int VAR_3, VAR_4, VAR_5;
uint32_t header;
uint8_t *buf, *buf2, *end;
AVCodecContext avctx;
if(id3v2_match(VAR_0->buf))
return AVPROBE_SCORE_MAX/2+1;
VAR_1 = 0;
buf = VAR_0->buf;
end = buf + FFMIN(4096, ... | [
"static int FUNC_0(AVProbeData *VAR_0)\n{",
"int VAR_1, VAR_2;",
"int VAR_3, VAR_4, VAR_5;",
"uint32_t header;",
"uint8_t *buf, *buf2, *end;",
"AVCodecContext avctx;",
"if(id3v2_match(VAR_0->buf))\nreturn AVPROBE_SCORE_MAX/2+1;",
"VAR_1 = 0;",
"buf = VAR_0->buf;",
"end = buf + FFMIN(4096, VAR_0->b... | [
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
17,
19
],
[
23
],
[
25
],
[
27
],
[
31
],
[
33
],
[
37
],
[
39
],
[
41
],
[
43,
45
],
[
47
],
[
49
],
[
51
... |
16,103 | static ImageInfoSpecific *qcow2_get_specific_info(BlockDriverState *bs)
{
BDRVQcow2State *s = bs->opaque;
ImageInfoSpecific *spec_info = g_new(ImageInfoSpecific, 1);
*spec_info = (ImageInfoSpecific){
.type = IMAGE_INFO_SPECIFIC_KIND_QCOW2,
.u.qcow2.data = g_new(ImageInfoSpecificQCow... | true | qemu | 0a12f6f80eeebeebd492db7d8c4237fe5c712f68 | static ImageInfoSpecific *qcow2_get_specific_info(BlockDriverState *bs)
{
BDRVQcow2State *s = bs->opaque;
ImageInfoSpecific *spec_info = g_new(ImageInfoSpecific, 1);
*spec_info = (ImageInfoSpecific){
.type = IMAGE_INFO_SPECIFIC_KIND_QCOW2,
.u.qcow2.data = g_new(ImageInfoSpecificQCow... | {
"code": [
" ImageInfoSpecific *spec_info = g_new(ImageInfoSpecific, 1);"
],
"line_no": [
7
]
} | static ImageInfoSpecific *FUNC_0(BlockDriverState *bs)
{
BDRVQcow2State *s = bs->opaque;
ImageInfoSpecific *spec_info = g_new(ImageInfoSpecific, 1);
*spec_info = (ImageInfoSpecific){
.type = IMAGE_INFO_SPECIFIC_KIND_QCOW2,
.u.qcow2.data = g_new(ImageInfoSpecificQCow2, 1),
};
... | [
"static ImageInfoSpecific *FUNC_0(BlockDriverState *bs)\n{",
"BDRVQcow2State *s = bs->opaque;",
"ImageInfoSpecific *spec_info = g_new(ImageInfoSpecific, 1);",
"*spec_info = (ImageInfoSpecific){",
".type = IMAGE_INFO_SPECIFIC_KIND_QCOW2,\n.u.qcow2.data = g_new(ImageInfoSpecificQCow2, 1),\n};",
"if (s->qco... | [
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
13,
15,
17
],
[
19
],
[
21
],
[
23,
25,
27
],
[
29
],
[
31
],
[
33,
35,
37,
39,
41,
43,
45,
47,
49
],
[
51
],
[
57
],
[
59... |
16,104 | static int gif_video_probe(AVProbeData * pd)
{
const uint8_t *p, *p_end;
int bits_per_pixel, has_global_palette, ext_code, ext_len;
int gce_flags, gce_disposal;
if (pd->buf_size < 24 ||
memcmp(pd->buf, gif89a_sig, 6) != 0)
return 0;
p_end = pd->buf + pd->buf_size;
p = ... | true | FFmpeg | 0b54f3c0878a3acaa9142e4f24942e762d97e350 | static int gif_video_probe(AVProbeData * pd)
{
const uint8_t *p, *p_end;
int bits_per_pixel, has_global_palette, ext_code, ext_len;
int gce_flags, gce_disposal;
if (pd->buf_size < 24 ||
memcmp(pd->buf, gif89a_sig, 6) != 0)
return 0;
p_end = pd->buf + pd->buf_size;
p = ... | {
"code": [
"static int gif_video_probe(AVProbeData * pd)",
" const uint8_t *p, *p_end;",
" int bits_per_pixel, has_global_palette, ext_code, ext_len;",
" int gce_flags, gce_disposal;",
" if (pd->buf_size < 24 ||",
" memcmp(pd->buf, gif89a_sig, 6) != 0)",
" return... | static int FUNC_0(AVProbeData * VAR_0)
{
const uint8_t *VAR_1, *p_end;
int VAR_2, VAR_3, VAR_4, VAR_5;
int VAR_6, VAR_7;
if (VAR_0->buf_size < 24 ||
memcmp(VAR_0->buf, gif89a_sig, 6) != 0)
return 0;
p_end = VAR_0->buf + VAR_0->buf_size;
VAR_1 = VAR_0->buf + 6;
VAR... | [
"static int FUNC_0(AVProbeData * VAR_0)\n{",
"const uint8_t *VAR_1, *p_end;",
"int VAR_2, VAR_3, VAR_4, VAR_5;",
"int VAR_6, VAR_7;",
"if (VAR_0->buf_size < 24 ||\nmemcmp(VAR_0->buf, gif89a_sig, 6) != 0)\nreturn 0;",
"p_end = VAR_0->buf + VAR_0->buf_size;",
"VAR_1 = VAR_0->buf + 6;",
"VAR_2 = (VAR_1[4... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
1,
0,
1,
1,
1,
1,
1,
1,
0,
0,
1,
1,
1,
0,
1,
0,
0,
1,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
13,
15,
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29,
31
],
[
33
],
[
35,
37
],
[
39,
41
],
[
43
],
[
45,
47
],
[
49
... |
16,105 | static int vcr2_init_sequence(AVCodecContext *avctx)
{
Mpeg1Context *s1 = avctx->priv_data;
MpegEncContext *s = &s1->mpeg_enc_ctx;
int i, v, ret;
/* start new MPEG-1 context decoding */
s->out_format = FMT_MPEG1;
if (s1->mpeg_enc_ctx_allocated) {
ff_mpv_common_end(s);
}
... | false | FFmpeg | dcc39ee10e82833ce24aa57926c00ffeb1948198 | static int vcr2_init_sequence(AVCodecContext *avctx)
{
Mpeg1Context *s1 = avctx->priv_data;
MpegEncContext *s = &s1->mpeg_enc_ctx;
int i, v, ret;
s->out_format = FMT_MPEG1;
if (s1->mpeg_enc_ctx_allocated) {
ff_mpv_common_end(s);
}
s->width = avctx->coded_... | {
"code": [],
"line_no": []
} | static int FUNC_0(AVCodecContext *VAR_0)
{
Mpeg1Context *s1 = VAR_0->priv_data;
MpegEncContext *s = &s1->mpeg_enc_ctx;
int VAR_1, VAR_2, VAR_3;
s->out_format = FMT_MPEG1;
if (s1->mpeg_enc_ctx_allocated) {
ff_mpv_common_end(s);
}
s->width = VAR_0->coded_wi... | [
"static int FUNC_0(AVCodecContext *VAR_0)\n{",
"Mpeg1Context *s1 = VAR_0->priv_data;",
"MpegEncContext *s = &s1->mpeg_enc_ctx;",
"int VAR_1, VAR_2, VAR_3;",
"s->out_format = FMT_MPEG1;",
"if (s1->mpeg_enc_ctx_allocated) {",
"ff_mpv_common_end(s);",
"}",
"s->width = VAR_0->coded_width;",
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
33
],
[
37,
39,
41,
43,
45,
47,
49
],
[
53
],
[
55,
57
],
[... |
16,106 | static void writer_print_time(WriterContext *wctx, const char *key,
int64_t ts, const AVRational *time_base, int is_duration)
{
char buf[128];
if ((!is_duration && ts == AV_NOPTS_VALUE) || (is_duration && ts == 0)) {
writer_print_string(wctx, key, "N/A", 1);
} e... | false | FFmpeg | cbba331aa02f29870581ff0b7ded7477b279ae2c | static void writer_print_time(WriterContext *wctx, const char *key,
int64_t ts, const AVRational *time_base, int is_duration)
{
char buf[128];
if ((!is_duration && ts == AV_NOPTS_VALUE) || (is_duration && ts == 0)) {
writer_print_string(wctx, key, "N/A", 1);
} e... | {
"code": [],
"line_no": []
} | static void FUNC_0(WriterContext *VAR_0, const char *VAR_1,
int64_t VAR_2, const AVRational *VAR_3, int VAR_4)
{
char VAR_5[128];
if ((!VAR_4 && VAR_2 == AV_NOPTS_VALUE) || (VAR_4 && VAR_2 == 0)) {
writer_print_string(VAR_0, VAR_1, "N/A", 1);
} else {
d... | [
"static void FUNC_0(WriterContext *VAR_0, const char *VAR_1,\nint64_t VAR_2, const AVRational *VAR_3, int VAR_4)\n{",
"char VAR_5[128];",
"if ((!VAR_4 && VAR_2 == AV_NOPTS_VALUE) || (VAR_4 && VAR_2 == 0)) {",
"writer_print_string(VAR_0, VAR_1, \"N/A\", 1);",
"} else {",
"double VAR_6 = VAR_2 * av_q2d(*VAR... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
]
] |
16,107 | static void fill_yuv_image(AVFrame *pict, int frame_index,
int width, int height)
{
int x, y, i, ret;
/* when we pass a frame to the encoder, it may keep a reference to it
* internally;
* make sure we do not overwrite it here
*/
ret = av_frame_make_writabl... | true | FFmpeg | 3115550abe96de674dac42f02a0b464e137bfc20 | static void fill_yuv_image(AVFrame *pict, int frame_index,
int width, int height)
{
int x, y, i, ret;
ret = av_frame_make_writable(pict);
if (ret < 0)
exit(1);
i = frame_index;
for (y = 0; y < height; y++)
for (x = 0; x < wi... | {
"code": [
" int x, y, i, ret;",
" ret = av_frame_make_writable(pict);",
" if (ret < 0)",
" exit(1);"
],
"line_no": [
7,
19,
21,
23
]
} | static void FUNC_0(AVFrame *VAR_0, int VAR_1,
int VAR_2, int VAR_3)
{
int VAR_4, VAR_5, VAR_6, VAR_7;
VAR_7 = av_frame_make_writable(VAR_0);
if (VAR_7 < 0)
exit(1);
VAR_6 = VAR_1;
for (VAR_5 = 0; VAR_5 < VAR_3; VAR_5++)
for ... | [
"static void FUNC_0(AVFrame *VAR_0, int VAR_1,\nint VAR_2, int VAR_3)\n{",
"int VAR_4, VAR_5, VAR_6, VAR_7;",
"VAR_7 = av_frame_make_writable(VAR_0);",
"if (VAR_7 < 0)\nexit(1);",
"VAR_6 = VAR_1;",
"for (VAR_5 = 0; VAR_5 < VAR_3; VAR_5++)",
"for (VAR_4 = 0; VAR_4 < VAR_2; VAR_4++)",
"VAR_0->data[0][VA... | [
0,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
19
],
[
21,
23
],
[
27
],
[
33
],
[
35
],
[
37
],
[
43
],
[
45
],
[
47
],
[
49
],
[
51
],
[
53
],
[
55
]
] |
16,108 | static int get_int32(QEMUFile *f, void *pv, size_t size)
{
int32_t *v = pv;
qemu_get_sbe32s(f, v);
return 0;
}
| true | qemu | 60fe637bf0e4d7989e21e50f52526444765c63b4 | static int get_int32(QEMUFile *f, void *pv, size_t size)
{
int32_t *v = pv;
qemu_get_sbe32s(f, v);
return 0;
}
| {
"code": [],
"line_no": []
} | static int FUNC_0(QEMUFile *VAR_0, void *VAR_1, size_t VAR_2)
{
int32_t *v = VAR_1;
qemu_get_sbe32s(VAR_0, v);
return 0;
}
| [
"static int FUNC_0(QEMUFile *VAR_0, void *VAR_1, size_t VAR_2)\n{",
"int32_t *v = VAR_1;",
"qemu_get_sbe32s(VAR_0, v);",
"return 0;",
"}"
] | [
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
]
] |
16,110 | static long do_rt_sigreturn_v1(CPUARMState *env)
{
abi_ulong frame_addr;
struct rt_sigframe_v1 *frame = NULL;
sigset_t host_set;
/*
* Since we stacked the signal on a 64-bit boundary,
* then 'sp' should be word aligned here. If it's
* not, then the user is trying to mess with u... | true | qemu | c599d4d6d6e9bfdb64e54c33a22cb26e3496b96d | static long do_rt_sigreturn_v1(CPUARMState *env)
{
abi_ulong frame_addr;
struct rt_sigframe_v1 *frame = NULL;
sigset_t host_set;
frame_addr = env->regs[13];
trace_user_do_rt_sigreturn(env, frame_addr);
if (frame_addr & 7) {
goto badframe;
}
if (!lock_u... | {
"code": [
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" ret... | static long FUNC_0(CPUARMState *VAR_0)
{
abi_ulong frame_addr;
struct rt_sigframe_v1 *VAR_1 = NULL;
sigset_t host_set;
frame_addr = VAR_0->regs[13];
trace_user_do_rt_sigreturn(VAR_0, frame_addr);
if (frame_addr & 7) {
goto badframe;
}
if (!lock_user_st... | [
"static long FUNC_0(CPUARMState *VAR_0)\n{",
"abi_ulong frame_addr;",
"struct rt_sigframe_v1 *VAR_1 = NULL;",
"sigset_t host_set;",
"frame_addr = VAR_0->regs[13];",
"trace_user_do_rt_sigreturn(VAR_0, frame_addr);",
"if (frame_addr & 7) {",
"goto badframe;",
"}",
"if (!lock_user_struct(VERIFY_READ,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
35
],
[
37
],
[
39
],
[
43
],
[
45
],
[
49
],
[
51
],
[
53
],
[
57,
59
],
[
63,
67,... |
16,111 | static int decode_q_branch(SnowContext *s, int level, int x, int y){
const int w= s->b_width << s->block_max_depth;
const int rem_depth= s->block_max_depth - level;
const int index= (x + y*w) << rem_depth;
int trx= (x+1)<<rem_depth;
const BlockNode *left = x ? &s->block[index-1] : &null_block;... | true | FFmpeg | c3b9bbcc6edf2d83fe4857484cfa0839872188c6 | static int decode_q_branch(SnowContext *s, int level, int x, int y){
const int w= s->b_width << s->block_max_depth;
const int rem_depth= s->block_max_depth - level;
const int index= (x + y*w) << rem_depth;
int trx= (x+1)<<rem_depth;
const BlockNode *left = x ? &s->block[index-1] : &null_block;... | {
"code": [
" l += get_symbol(&s->c, &s->block_state[32], 1);",
" cb+= get_symbol(&s->c, &s->block_state[64], 1);",
" cr+= get_symbol(&s->c, &s->block_state[96], 1);"
],
"line_no": [
63,
67,
69
]
} | static int FUNC_0(SnowContext *VAR_0, int VAR_1, int VAR_2, int VAR_3){
const int VAR_4= VAR_0->b_width << VAR_0->block_max_depth;
const int VAR_5= VAR_0->block_max_depth - VAR_1;
const int VAR_6= (VAR_2 + VAR_3*VAR_4) << VAR_5;
int VAR_7= (VAR_2+1)<<VAR_5;
const BlockNode *VAR_8 = VAR_2 ? &VA... | [
"static int FUNC_0(SnowContext *VAR_0, int VAR_1, int VAR_2, int VAR_3){",
"const int VAR_4= VAR_0->b_width << VAR_0->block_max_depth;",
"const int VAR_5= VAR_0->block_max_depth - VAR_1;",
"const int VAR_6= (VAR_2 + VAR_3*VAR_4) << VAR_5;",
"int VAR_7= (VAR_2+1)<<VAR_5;",
"const BlockNode *VAR_8 = VAR_2 ... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1
],
[
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
25
],
[
27
],
[
29
],
[
31
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[... |
16,113 | cl_program av_opencl_compile(const char *program_name, const char *build_opts)
{
int i;
cl_int status, build_status;
int kernel_code_idx = 0;
const char *kernel_source;
size_t kernel_code_len;
char* ptr = NULL;
cl_program program = NULL;
size_t log_size;
char *log = NULL;
... | true | FFmpeg | 6b852a3fd94210779491d51441a3439831841a55 | cl_program av_opencl_compile(const char *program_name, const char *build_opts)
{
int i;
cl_int status, build_status;
int kernel_code_idx = 0;
const char *kernel_source;
size_t kernel_code_len;
char* ptr = NULL;
cl_program program = NULL;
size_t log_size;
char *log = NULL;
... | {
"code": [
" const char *kernel_source;"
],
"line_no": [
11
]
} | cl_program FUNC_0(const char *program_name, const char *build_opts)
{
int VAR_0;
cl_int status, build_status;
int VAR_1 = 0;
const char *VAR_2;
size_t kernel_code_len;
char* VAR_3 = NULL;
cl_program program = NULL;
size_t log_size;
char *VAR_4 = NULL;
LOCK_OPENCL;
... | [
"cl_program FUNC_0(const char *program_name, const char *build_opts)\n{",
"int VAR_0;",
"cl_int status, build_status;",
"int VAR_1 = 0;",
"const char *VAR_2;",
"size_t kernel_code_len;",
"char* VAR_3 = NULL;",
"cl_program program = NULL;",
"size_t log_size;",
"char *VAR_4 = NULL;",
"LOCK_OPENCL;... | [
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
25
],
[
27
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
... |
16,114 | static void output_segment_list(OutputStream *os, AVIOContext *out, DASHContext *c)
{
int i, start_index = 0, start_number = 1;
if (c->window_size) {
start_index = FFMAX(os->nb_segments - c->window_size, 0);
start_number = FFMAX(os->segment_index - c->window_size, 1);
}
if (c... | true | FFmpeg | e65849a70bfb401306038d41ebd8b5750deb3cfd | static void output_segment_list(OutputStream *os, AVIOContext *out, DASHContext *c)
{
int i, start_index = 0, start_number = 1;
if (c->window_size) {
start_index = FFMAX(os->nb_segments - c->window_size, 0);
start_number = FFMAX(os->segment_index - c->window_size, 1);
}
if (c... | {
"code": [
" avio_printf(out, \"duration=\\\"%d\\\" \", c->last_duration);",
" avio_printf(out, \"\\t\\t\\t\\t<SegmentList timescale=\\\"%d\\\" duration=\\\"%d\\\" startNumber=\\\"%d\\\">\\n\", AV_TIME_BASE, c->last_duration, start_number);",
" avio_printf(out, \"\\t\\t\\t\\t<Seg... | static void FUNC_0(OutputStream *VAR_0, AVIOContext *VAR_1, DASHContext *VAR_2)
{
int VAR_3, VAR_4 = 0, VAR_5 = 1;
if (VAR_2->window_size) {
VAR_4 = FFMAX(VAR_0->nb_segments - VAR_2->window_size, 0);
VAR_5 = FFMAX(VAR_0->segment_index - VAR_2->window_size, 1);
}
if (VAR_2->us... | [
"static void FUNC_0(OutputStream *VAR_0, AVIOContext *VAR_1, DASHContext *VAR_2)\n{",
"int VAR_3, VAR_4 = 0, VAR_5 = 1;",
"if (VAR_2->window_size) {",
"VAR_4 = FFMAX(VAR_0->nb_segments - VAR_2->window_size, 0);",
"VAR_5 = FFMAX(VAR_0->segment_index - VAR_2->window_size, 1);",
"}",
"if (VAR_2->use_tem... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
17
],
[
19
],
[
21
],
[
23,
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41,
43
],
[
45
... |
16,115 | int av_cold ff_ivi_init_tiles(IVIPlaneDesc *planes, int tile_width, int tile_height)
{
int p, b, x, y, x_tiles, y_tiles, t_width, t_height;
IVIBandDesc *band;
IVITile *tile, *ref_tile;
for (p = 0; p < 3; p++) {
t_width = !p ? tile_width : (tile_width + 3) >> 2;
t_... | true | FFmpeg | 92e2b59dec8c0124a209ce24f23450df9607d9d8 | int av_cold ff_ivi_init_tiles(IVIPlaneDesc *planes, int tile_width, int tile_height)
{
int p, b, x, y, x_tiles, y_tiles, t_width, t_height;
IVIBandDesc *band;
IVITile *tile, *ref_tile;
for (p = 0; p < 3; p++) {
t_width = !p ? tile_width : (tile_width + 3) >> 2;
t_... | {
"code": [],
"line_no": []
} | int VAR_0 ff_ivi_init_tiles(IVIPlaneDesc *planes, int tile_width, int tile_height)
{
int p, b, x, y, x_tiles, y_tiles, t_width, t_height;
IVIBandDesc *band;
IVITile *tile, *ref_tile;
for (p = 0; p < 3; p++) {
t_width = !p ? tile_width : (tile_width + 3) >> 2;
t_he... | [
"int VAR_0 ff_ivi_init_tiles(IVIPlaneDesc *planes, int tile_width, int tile_height)\n{",
"int p, b, x, y, x_tiles, y_tiles, t_width, t_height;",
"IVIBandDesc *band;",
"IVITile *tile, *ref_tile;",
"for (p = 0; p < 3; p++) {",
"t_width = !p ? tile_width : (tile_width + 3) >> 2;",
"t_height ... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
17
],
[
21
],
[
23
],
[
25
],
[
27
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
45
],
[
47
],
[
49,
51
],
[... |
16,116 | int spapr_h_cas_compose_response(sPAPRMachineState *spapr,
target_ulong addr, target_ulong size,
bool cpu_update)
{
void *fdt, *fdt_skel;
sPAPRDeviceTreeUpdateHeader hdr = { .version_id = 1 };
sPAPRMachineClass *smc = SPAPR_MACHINE_GET_... | true | qemu | 6787d27b04a79524c547c60701400eb0418e3533 | int spapr_h_cas_compose_response(sPAPRMachineState *spapr,
target_ulong addr, target_ulong size,
bool cpu_update)
{
void *fdt, *fdt_skel;
sPAPRDeviceTreeUpdateHeader hdr = { .version_id = 1 };
sPAPRMachineClass *smc = SPAPR_MACHINE_GET_... | {
"code": [
" bool cpu_update)",
" sPAPRMachineClass *smc = SPAPR_MACHINE_GET_CLASS(qdev_get_machine());",
" if (spapr_ovec_test(spapr->ov5_cas, OV5_DRCONF_MEMORY)) {",
" g_assert(smc->dr_lmb_enabled);",
" _FDT((spapr_populate_drconf_memory(spapr... | int FUNC_0(sPAPRMachineState *VAR_0,
target_ulong VAR_1, target_ulong VAR_2,
bool VAR_3)
{
void *VAR_4, *VAR_5;
sPAPRDeviceTreeUpdateHeader hdr = { .version_id = 1 };
sPAPRMachineClass *smc = SPAPR_MACHINE_GET_CLASS(qdev_get_machine());... | [
"int FUNC_0(sPAPRMachineState *VAR_0,\ntarget_ulong VAR_1, target_ulong VAR_2,\nbool VAR_3)\n{",
"void *VAR_4, *VAR_5;",
"sPAPRDeviceTreeUpdateHeader hdr = { .version_id = 1 };",
"sPAPRMachineClass *smc = SPAPR_MACHINE_GET_CLASS(qdev_get_machine());",
"VAR_2 -= sizeof(hdr);",
"VAR_5 = g_malloc0(VAR_2);",
... | [
1,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5,
7
],
[
9
],
[
11
],
[
13
],
[
17
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
43
],
[
45
],
[
47
],
[
53
],
[
55
],
[
57
... |
16,117 | int do_store_msr (CPUPPCState *env, target_ulong value)
{
int enter_pm;
value &= env->msr_mask;
if (((value >> MSR_IR) & 1) != msr_ir ||
((value >> MSR_DR) & 1) != msr_dr) {
/* Flush all tlb when changing translation mode */
tlb_flush(env, 1);
env->interrupt_request... | true | qemu | 25ba3a681213390e9212dbc987d61843c3b41d5b | int do_store_msr (CPUPPCState *env, target_ulong value)
{
int enter_pm;
value &= env->msr_mask;
if (((value >> MSR_IR) & 1) != msr_ir ||
((value >> MSR_DR) & 1) != msr_dr) {
tlb_flush(env, 1);
env->interrupt_request |= CPU_INTERRUPT_EXITTB;
}
#if !defined (CO... | {
"code": [
" msr_ip = (value >> MSR_IP) & 1;"
],
"line_no": [
89
]
} | int FUNC_0 (CPUPPCState *VAR_0, target_ulong VAR_1)
{
int VAR_2;
VAR_1 &= VAR_0->msr_mask;
if (((VAR_1 >> MSR_IR) & 1) != msr_ir ||
((VAR_1 >> MSR_DR) & 1) != msr_dr) {
tlb_flush(VAR_0, 1);
VAR_0->interrupt_request |= CPU_INTERRUPT_EXITTB;
}
#if !defined (CON... | [
"int FUNC_0 (CPUPPCState *VAR_0, target_ulong VAR_1)\n{",
"int VAR_2;",
"VAR_1 &= VAR_0->msr_mask;",
"if (((VAR_1 >> MSR_IR) & 1) != msr_ir ||\n((VAR_1 >> MSR_DR) & 1) != msr_dr) {",
"tlb_flush(VAR_0, 1);",
"VAR_0->interrupt_request |= CPU_INTERRUPT_EXITTB;",
"}",
"#if !defined (CONFIG_USER_ONLY)\nif ... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11,
13
],
[
17
],
[
19
],
[
21
],
[
23,
25,
27
],
[
31
],
[
33
],
[
35
],
[
39
],
[
41
],
[
43,
45,
47
],
[
49
],
[
51
],
[
53,
55... |
16,118 | static int filter_frame(AVFilterLink *inlink, AVFrame *insamplesref)
{
AResampleContext *aresample = inlink->dst->priv;
const int n_in = insamplesref->nb_samples;
int64_t delay;
int n_out = n_in * aresample->ratio + 32;
AVFilterLink *const outlink = inlink->dst->outputs[0];
AVFrame... | true | FFmpeg | c90b88090c260a0af018b6c1e955266e24ebf6f4 | static int filter_frame(AVFilterLink *inlink, AVFrame *insamplesref)
{
AResampleContext *aresample = inlink->dst->priv;
const int n_in = insamplesref->nb_samples;
int64_t delay;
int n_out = n_in * aresample->ratio + 32;
AVFilterLink *const outlink = inlink->dst->outputs[0];
AVFrame... | {
"code": [
" if(!outsamplesref)"
],
"line_no": [
33
]
} | static int FUNC_0(AVFilterLink *VAR_0, AVFrame *VAR_1)
{
AResampleContext *aresample = VAR_0->dst->priv;
const int VAR_2 = VAR_1->nb_samples;
int64_t delay;
int VAR_3 = VAR_2 * aresample->ratio + 32;
AVFilterLink *const outlink = VAR_0->dst->outputs[0];
AVFrame *outsamplesref;
... | [
"static int FUNC_0(AVFilterLink *VAR_0, AVFrame *VAR_1)\n{",
"AResampleContext *aresample = VAR_0->dst->priv;",
"const int VAR_2 = VAR_1->nb_samples;",
"int64_t delay;",
"int VAR_3 = VAR_2 * aresample->ratio + 32;",
"AVFilterLink *const outlink = VAR_0->dst->outputs[0];",
"AVFrame *outsamplesref;... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
21
],
[
23,
25
],
[
29
],
[
33,
35
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[
51
],
[
53
... |
16,119 | static void mem_add(MemoryListener *listener, MemoryRegionSection *section)
{
AddressSpaceDispatch *d = container_of(listener, AddressSpaceDispatch, listener);
MemoryRegionSection now = *section, remain = *section;
if ((now.offset_within_address_space & ~TARGET_PAGE_MASK)
|| (now.size < TARGE... | true | qemu | 86a8623692b1b559a419a92eb8b6897c221bca74 | static void mem_add(MemoryListener *listener, MemoryRegionSection *section)
{
AddressSpaceDispatch *d = container_of(listener, AddressSpaceDispatch, listener);
MemoryRegionSection now = *section, remain = *section;
if ((now.offset_within_address_space & ~TARGET_PAGE_MASK)
|| (now.size < TARGE... | {
"code": [
" MemoryRegionSection now = *section, remain = *section;"
],
"line_no": [
7
]
} | static void FUNC_0(MemoryListener *VAR_0, MemoryRegionSection *VAR_1)
{
AddressSpaceDispatch *d = container_of(VAR_0, AddressSpaceDispatch, VAR_0);
MemoryRegionSection now = *VAR_1, remain = *VAR_1;
if ((now.offset_within_address_space & ~TARGET_PAGE_MASK)
|| (now.size < TARGET_PAGE_SIZE)) {
... | [
"static void FUNC_0(MemoryListener *VAR_0, MemoryRegionSection *VAR_1)\n{",
"AddressSpaceDispatch *d = container_of(VAR_0, AddressSpaceDispatch, VAR_0);",
"MemoryRegionSection now = *VAR_1, remain = *VAR_1;",
"if ((now.offset_within_address_space & ~TARGET_PAGE_MASK)\n|| (now.size < TARGET_PAGE_SIZE)) {",
"... | [
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11,
13
],
[
15,
17,
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
... |
16,120 | static int decode_frame(AVCodecContext *avctx,
void *data, int *got_frame,
AVPacket *avpkt)
{
AnsiContext *s = avctx->priv_data;
uint8_t *buf = avpkt->data;
int buf_size = avpkt->size;
const uint8_t *buf_end = buf+buf_size;
int ret, i... | true | FFmpeg | d42ec8433c687fcbccefa51a7716d81920218e4f | static int decode_frame(AVCodecContext *avctx,
void *data, int *got_frame,
AVPacket *avpkt)
{
AnsiContext *s = avctx->priv_data;
uint8_t *buf = avpkt->data;
int buf_size = avpkt->size;
const uint8_t *buf_end = buf+buf_size;
int ret, i... | {
"code": [
" if (s->nb_args < MAX_NB_ARGS)"
],
"line_no": [
149
]
} | static int FUNC_0(AVCodecContext *VAR_0,
void *VAR_1, int *VAR_2,
AVPacket *VAR_3)
{
AnsiContext *s = VAR_0->priv_data;
uint8_t *buf = VAR_3->VAR_1;
int VAR_4 = VAR_3->size;
const uint8_t *VAR_5 = buf+VAR_4;
int VAR_6, VAR_7, VAR_8;
... | [
"static int FUNC_0(AVCodecContext *VAR_0,\nvoid *VAR_1, int *VAR_2,\nAVPacket *VAR_3)\n{",
"AnsiContext *s = VAR_0->priv_data;",
"uint8_t *buf = VAR_3->VAR_1;",
"int VAR_4 = VAR_3->size;",
"const uint8_t *VAR_5 = buf+VAR_4;",
"int VAR_6, VAR_7, VAR_8;",
"if ((VAR_6 = ff_reget_buffer(VAR_0, s->frame)) ... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
[
1,
3,
5,
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
21,
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[... |
16,121 | static void load_symbols(struct elfhdr *hdr, int fd)
{
unsigned int i, nsyms;
struct elf_shdr sechdr, symtab, strtab;
char *strings;
struct syminfo *s;
struct elf_sym *syms;
lseek(fd, hdr->e_shoff, SEEK_SET);
for (i = 0; i < hdr->e_shnum; i++) {
if (read(fd, &sechdr, sizeo... | true | qemu | 29718712eb2e53c09d28f08e39f6514d690f6fd3 | static void load_symbols(struct elfhdr *hdr, int fd)
{
unsigned int i, nsyms;
struct elf_shdr sechdr, symtab, strtab;
char *strings;
struct syminfo *s;
struct elf_sym *syms;
lseek(fd, hdr->e_shoff, SEEK_SET);
for (i = 0; i < hdr->e_shnum; i++) {
if (read(fd, &sechdr, sizeo... | {
"code": [
" struct elf_sym *syms;",
" if (!syms)",
" if (!s->disas_strtab)",
" if (read(fd, syms, symtab.sh_size) != symtab.sh_size)",
" syms = realloc(syms, nsyms * sizeof(*syms));",
" if (read(fd, strings, strtab.sh_size) != strtab.sh_size)"
],
"line_no": [
13,
... | static void FUNC_0(struct elfhdr *VAR_0, int VAR_1)
{
unsigned int VAR_2, VAR_3;
struct elf_shdr VAR_4, VAR_5, VAR_6;
char *VAR_7;
struct syminfo *VAR_8;
struct elf_sym *VAR_9;
lseek(VAR_1, VAR_0->e_shoff, SEEK_SET);
for (VAR_2 = 0; VAR_2 < VAR_0->e_shnum; VAR_2++) {
if (r... | [
"static void FUNC_0(struct elfhdr *VAR_0, int VAR_1)\n{",
"unsigned int VAR_2, VAR_3;",
"struct elf_shdr VAR_4, VAR_5, VAR_6;",
"char *VAR_7;",
"struct syminfo *VAR_8;",
"struct elf_sym *VAR_9;",
"lseek(VAR_1, VAR_0->e_shoff, SEEK_SET);",
"for (VAR_2 = 0; VAR_2 < VAR_0->e_shnum; VAR_2++) {",
"if (re... | [
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
1,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
17
],
[
19
],
[
21,
23
],
[
25,
27
],
[
29,
31
],
[
33
],
[
35,
37
],
[
39,
41,
43
],
[
45,
47
],
[
49,
51
... |
16,123 | av_cold int ff_snow_common_init(AVCodecContext *avctx){
SnowContext *s = avctx->priv_data;
int width, height;
int i, j;
s->avctx= avctx;
s->max_ref_frames=1; //just make sure it's not an invalid value in case of no initial keyframe
ff_me_cmp_init(&s->mecc, avctx);
ff_hpeldsp_init... | true | FFmpeg | dd369c9adbdd6b5bb306db15dce9ad8d370385fc | av_cold int ff_snow_common_init(AVCodecContext *avctx){
SnowContext *s = avctx->priv_data;
int width, height;
int i, j;
s->avctx= avctx;
s->max_ref_frames=1;
ff_me_cmp_init(&s->mecc, avctx);
ff_hpeldsp_init(&s->hdsp, avctx->flags);
ff_videodsp_init(&s->vdsp, 8);
ff_dwt... | {
"code": [],
"line_no": []
} | av_cold int FUNC_0(AVCodecContext *avctx){
SnowContext *s = avctx->priv_data;
int VAR_0, VAR_1;
int VAR_2, VAR_3;
s->avctx= avctx;
s->max_ref_frames=1;
ff_me_cmp_init(&s->mecc, avctx);
ff_hpeldsp_init(&s->hdsp, avctx->flags);
ff_videodsp_init(&s->vdsp, 8);
ff_dwt_init(... | [
"av_cold int FUNC_0(AVCodecContext *avctx){",
"SnowContext *s = avctx->priv_data;",
"int VAR_0, VAR_1;",
"int VAR_2, VAR_3;",
"s->avctx= avctx;",
"s->max_ref_frames=1;",
"ff_me_cmp_init(&s->mecc, avctx);",
"ff_hpeldsp_init(&s->hdsp, avctx->flags);",
"ff_videodsp_init(&s->vdsp, 8);",
"ff_dwt_init(&... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1
],
[
3
],
[
5
],
[
7
],
[
11
],
[
13
],
[
18
],
[
20
],
[
22
],
[
24
],
[
26
],
[
30,
32,
34,
36
],
[
38,
40,
42
],
[
46,
48,
50,
52,
54,
56,
58,
60,
62... |
16,125 | static int hdev_open(BlockDriverState *bs, const char *filename, int flags)
{
BDRVRawState *s = bs->opaque;
#if defined(__APPLE__) && defined(__MACH__)
if (strstart(filename, "/dev/cdrom", NULL)) {
kern_return_t kernResult;
io_iterator_t mediaIterator;
char bsdPath[ MAXPATHLEN ]... | true | qemu | da888d37b0b85fc23e4ea55ab8b0c482d4918afb | static int hdev_open(BlockDriverState *bs, const char *filename, int flags)
{
BDRVRawState *s = bs->opaque;
#if defined(__APPLE__) && defined(__MACH__)
if (strstart(filename, "/dev/cdrom", NULL)) {
kern_return_t kernResult;
io_iterator_t mediaIterator;
char bsdPath[ MAXPATHLEN ]... | {
"code": [
" return raw_open_common(bs, filename, flags, 0);"
],
"line_no": [
87
]
} | static int FUNC_0(BlockDriverState *VAR_0, const char *VAR_1, int VAR_2)
{
BDRVRawState *s = VAR_0->opaque;
#if defined(__APPLE__) && defined(__MACH__)
if (strstart(VAR_1, "/dev/cdrom", NULL)) {
kern_return_t kernResult;
io_iterator_t mediaIterator;
char VAR_3[ MAXPATHLEN ];
... | [
"static int FUNC_0(BlockDriverState *VAR_0, const char *VAR_1, int VAR_2)\n{",
"BDRVRawState *s = VAR_0->opaque;",
"#if defined(__APPLE__) && defined(__MACH__)\nif (strstart(VAR_1, \"/dev/cdrom\", NULL)) {",
"kern_return_t kernResult;",
"io_iterator_t mediaIterator;",
"char VAR_3[ MAXPATHLEN ];",
"int V... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0
] | [
[
1,
3
],
[
5
],
[
9,
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
23
],
[
25
],
[
29
],
[
31
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49
],
... |
16,127 | void kvm_inject_x86_mce(CPUState *cenv, int bank, uint64_t status,
uint64_t mcg_status, uint64_t addr, uint64_t misc)
{
#ifdef KVM_CAP_MCE
struct kvm_x86_mce mce = {
.bank = bank,
.status = status,
.mcg_status = mcg_status,
.addr = addr,
.misc... | true | qemu | c0532a76b407af4b276dc5a62d8178db59857ea6 | void kvm_inject_x86_mce(CPUState *cenv, int bank, uint64_t status,
uint64_t mcg_status, uint64_t addr, uint64_t misc)
{
#ifdef KVM_CAP_MCE
struct kvm_x86_mce mce = {
.bank = bank,
.status = status,
.mcg_status = mcg_status,
.addr = addr,
.misc... | {
"code": [
" uint64_t mcg_status, uint64_t addr, uint64_t misc)"
],
"line_no": [
3
]
} | void FUNC_0(CPUState *VAR_0, int VAR_1, uint64_t VAR_2,
uint64_t VAR_3, uint64_t VAR_4, uint64_t VAR_5)
{
#ifdef KVM_CAP_MCE
struct kvm_x86_mce mce = {
.VAR_1 = VAR_1,
.VAR_2 = VAR_2,
.VAR_3 = VAR_3,
.VAR_4 = VAR_4,
.VAR_5 = VAR_5,
};
... | [
"void FUNC_0(CPUState *VAR_0, int VAR_1, uint64_t VAR_2,\nuint64_t VAR_3, uint64_t VAR_4, uint64_t VAR_5)\n{",
"#ifdef KVM_CAP_MCE\nstruct kvm_x86_mce mce = {",
".VAR_1 = VAR_1,\n.VAR_2 = VAR_2,\n.VAR_3 = VAR_3,\n.VAR_4 = VAR_4,\n.VAR_5 = VAR_5,\n};",
"struct kvm_x86_mce_data data = {",
".env = VAR_0,\n.mce... | [
1,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7,
9
],
[
11,
13,
15,
17,
19,
21
],
[
23
],
[
25,
27,
29
],
[
33
],
[
35,
37
]
] |
16,128 | static int asf_read_marker(AVFormatContext *s, int64_t size)
{
AVIOContext *pb = s->pb;
ASFContext *asf = s->priv_data;
int i, count, name_len, ret;
char name[1024];
avio_rl64(pb); // reserved 16 bytes
avio_rl64(pb); // ...
count = avio_rl32(pb); // markers... | true | FFmpeg | 7f9ec5593e04827249e7aeb466da06a98a0d7329 | static int asf_read_marker(AVFormatContext *s, int64_t size)
{
AVIOContext *pb = s->pb;
ASFContext *asf = s->priv_data;
int i, count, name_len, ret;
char name[1024];
avio_rl64(pb);
avio_rl64(pb);
count = avio_rl32(pb);
avio_rl16(pb);
... | {
"code": [
" for (i = 0; i < name_len; i++)"
],
"line_no": [
25
]
} | static int FUNC_0(AVFormatContext *VAR_0, int64_t VAR_1)
{
AVIOContext *pb = VAR_0->pb;
ASFContext *asf = VAR_0->priv_data;
int VAR_2, VAR_3, VAR_7, VAR_5;
char VAR_6[1024];
avio_rl64(pb);
avio_rl64(pb);
VAR_3 = avio_rl32(pb);
avio_rl16(pb); ... | [
"static int FUNC_0(AVFormatContext *VAR_0, int64_t VAR_1)\n{",
"AVIOContext *pb = VAR_0->pb;",
"ASFContext *asf = VAR_0->priv_data;",
"int VAR_2, VAR_3, VAR_7, VAR_5;",
"char VAR_6[1024];",
"avio_rl64(pb);",
"avio_rl64(pb);",
"VAR_3 = avio_rl32(pb);",
"avio_rl16(pb);",
"VAR_7 = avio_rl16(pb);",
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
31
],
[
33
],
[
35
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
... |
16,129 | static void xhci_events_update(XHCIState *xhci, int v)
{
XHCIInterrupter *intr = &xhci->intr[v];
dma_addr_t erdp;
unsigned int dp_idx;
bool do_irq = 0;
if (xhci->usbsts & USBSTS_HCH) {
return;
}
erdp = xhci_addr64(intr->erdp_low, intr->erdp_high);
if (erdp < intr->e... | true | qemu | 898248a32915024a4f01ce4f0c3519509fb703cb | static void xhci_events_update(XHCIState *xhci, int v)
{
XHCIInterrupter *intr = &xhci->intr[v];
dma_addr_t erdp;
unsigned int dp_idx;
bool do_irq = 0;
if (xhci->usbsts & USBSTS_HCH) {
return;
}
erdp = xhci_addr64(intr->erdp_low, intr->erdp_high);
if (erdp < intr->e... | {
"code": [
"static void xhci_events_update(XHCIState *xhci, int v)",
" XHCIInterrupter *intr = &xhci->intr[v];",
" dma_addr_t erdp;",
" unsigned int dp_idx;",
" bool do_irq = 0;",
" if (xhci->usbsts & USBSTS_HCH) {",
" erdp = xhci_addr64(intr->erdp_low, intr->erdp_high);... | static void FUNC_0(XHCIState *VAR_0, int VAR_1)
{
XHCIInterrupter *intr = &VAR_0->intr[VAR_1];
dma_addr_t erdp;
unsigned int VAR_2;
bool do_irq = 0;
if (VAR_0->usbsts & USBSTS_HCH) {
return;
}
erdp = xhci_addr64(intr->erdp_low, intr->erdp_high);
if (erdp < intr->er_... | [
"static void FUNC_0(XHCIState *VAR_0, int VAR_1)\n{",
"XHCIInterrupter *intr = &VAR_0->intr[VAR_1];",
"dma_addr_t erdp;",
"unsigned int VAR_2;",
"bool do_irq = 0;",
"if (VAR_0->usbsts & USBSTS_HCH) {",
"return;",
"}",
"erdp = xhci_addr64(intr->erdp_low, intr->erdp_high);",
"if (erdp < intr->er_sta... | [
1,
1,
1,
1,
1,
1,
0,
0,
1,
1,
1,
1,
1,
0,
0,
1,
1,
1,
1,
1,
1,
0,
1,
1,
0,
0,
0,
1,
1,
1,
1,
1,
1,
1,
1,
0,
1,
1,
1,
1,
1,
1,
0,
0,
1,
1,
0,
1,
1,
1,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
15
],
[
17
],
[
19
],
[
23
],
[
25,
27
],
[
29
],
[
31,
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
53
],
[
55
... |
16,130 | static int process_line(URLContext *h, char *line, int line_count,
int *new_location)
{
HTTPContext *s = h->priv_data;
char *tag, *p, *end;
/* end of header */
if (line[0] == '\0')
return 0;
p = line;
if (line_count == 0) {
while (!isspace(*p... | true | FFmpeg | b01f5ba2070e022e6cf6c1fa8410367e90e33b60 | static int process_line(URLContext *h, char *line, int line_count,
int *new_location)
{
HTTPContext *s = h->priv_data;
char *tag, *p, *end;
if (line[0] == '\0')
return 0;
p = line;
if (line_count == 0) {
while (!isspace(*p) && *p != '\0')
... | {
"code": [
" if (s->http_code >= 400 && s->http_code < 600 && s->http_code != 401) {"
],
"line_no": [
45
]
} | static int FUNC_0(URLContext *VAR_0, char *VAR_1, int VAR_2,
int *VAR_3)
{
HTTPContext *s = VAR_0->priv_data;
char *VAR_4, *VAR_5, *VAR_6;
if (VAR_1[0] == '\0')
return 0;
VAR_5 = VAR_1;
if (VAR_2 == 0) {
while (!isspace(*VAR_5) && *VAR_5 != ... | [
"static int FUNC_0(URLContext *VAR_0, char *VAR_1, int VAR_2,\nint *VAR_3)\n{",
"HTTPContext *s = VAR_0->priv_data;",
"char *VAR_4, *VAR_5, *VAR_6;",
"if (VAR_1[0] == '\\0')\nreturn 0;",
"VAR_5 = VAR_1;",
"if (VAR_2 == 0) {",
"while (!isspace(*VAR_5) && *VAR_5 != '\\0')\nVAR_5++;",
"while (isspace(*VA... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
15,
17
],
[
21
],
[
23
],
[
25,
27
],
[
29,
31
],
[
33
],
[
37
],
[
45
],
[
47
],
[
49,
51
],
[
53
],
[
55
],
[
57
],
[
59,
61
... |
16,131 | static void decode_p_block(FourXContext *f, uint16_t *dst, uint16_t *src,
int log2w, int log2h, int stride)
{
const int index = size2index[log2h][log2w];
const int h = 1 << log2h;
int code = get_vlc2(&f->gb,
block_type_vlc[1 - (f->ve... | true | FFmpeg | 44fe118e0a5fc4797ee49e1ce56108bde13f19dc | static void decode_p_block(FourXContext *f, uint16_t *dst, uint16_t *src,
int log2w, int log2h, int stride)
{
const int index = size2index[log2h][log2w];
const int h = 1 << log2h;
int code = get_vlc2(&f->gb,
block_type_vlc[1 - (f->ve... | {
"code": [
" if (f->g.buffer_end - f->g.buffer < 1) {",
" src += f->mv[bytestream2_get_byte(&f->g)];",
" if (f->g.buffer_end - f->g.buffer < 1) {",
" src += f->mv[bytestream2_get_byte(&f->g)];",
" if (f->g2.buffer_end - f->g2.buffer < 1){",
" mcdc(dst... | static void FUNC_0(FourXContext *VAR_0, uint16_t *VAR_1, uint16_t *VAR_2,
int VAR_3, int VAR_4, int VAR_5)
{
const int VAR_6 = size2index[VAR_4][VAR_3];
const int VAR_7 = 1 << VAR_4;
int VAR_8 = get_vlc2(&VAR_0->gb,
block_type_vlc[1 ... | [
"static void FUNC_0(FourXContext *VAR_0, uint16_t *VAR_1, uint16_t *VAR_2,\nint VAR_3, int VAR_4, int VAR_5)\n{",
"const int VAR_6 = size2index[VAR_4][VAR_3];",
"const int VAR_7 = 1 << VAR_4;",
"int VAR_8 = get_vlc2(&VAR_0->gb,\nblock_type_vlc[1 - (VAR_0->version > 1)][VAR_6].table,\nBLOCK_TYPE_VLC... | [
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
1,
0,
1,
0,
0,
0,
1,
0,
1,
0,
0,
0,
0,
1,
1,
0,
0,
1,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11,
13,
15
],
[
17
],
[
19
],
[
23
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[... |
16,133 | void ff_snow_vertical_compose97i_sse2(IDWTELEM *b0, IDWTELEM *b1, IDWTELEM *b2, IDWTELEM *b3, IDWTELEM *b4, IDWTELEM *b5, int width){
long i = width;
while(i & 0x1F)
{
i--;
b4[i] -= (W_DM*(b3[i] + b5[i])+W_DO)>>W_DS;
b3[i] -= (W_CM*(b2[i] + b4[i])+W_CO)>>W_CS;
b2[i] ... | true | FFmpeg | 629750290f6122a72e68c34cf94f521a90def2ef | void ff_snow_vertical_compose97i_sse2(IDWTELEM *b0, IDWTELEM *b1, IDWTELEM *b2, IDWTELEM *b3, IDWTELEM *b4, IDWTELEM *b5, int width){
long i = width;
while(i & 0x1F)
{
i--;
b4[i] -= (W_DM*(b3[i] + b5[i])+W_DO)>>W_DS;
b3[i] -= (W_CM*(b2[i] + b4[i])+W_CO)>>W_CS;
b2[i] ... | {
"code": [
" snow_vertical_compose_sse2_add(REG_a,\"xmm0\",\"xmm2\",\"xmm4\",\"xmm6\")",
" snow_vertical_compose_sse2_sra(\"2\",\"xmm0\",\"xmm2\",\"xmm4\",\"xmm6\")",
" \"pcmpeqd %%xmm1, %%xmm1 \\n\\t\"",
" \"psllw $15, %%xmm1 ... | void FUNC_0(IDWTELEM *VAR_0, IDWTELEM *VAR_1, IDWTELEM *VAR_2, IDWTELEM *VAR_3, IDWTELEM *VAR_4, IDWTELEM *VAR_5, int VAR_6){
long VAR_7 = VAR_6;
while(VAR_7 & 0x1F)
{
VAR_7--;
VAR_4[VAR_7] -= (W_DM*(VAR_3[VAR_7] + VAR_5[VAR_7])+W_DO)>>W_DS;
VAR_3[VAR_7] -= (W_CM*(VAR_2[VAR_7... | [
"void FUNC_0(IDWTELEM *VAR_0, IDWTELEM *VAR_1, IDWTELEM *VAR_2, IDWTELEM *VAR_3, IDWTELEM *VAR_4, IDWTELEM *VAR_5, int VAR_6){",
"long VAR_7 = VAR_6;",
"while(VAR_7 & 0x1F)\n{",
"VAR_7--;",
"VAR_4[VAR_7] -= (W_DM*(VAR_3[VAR_7] + VAR_5[VAR_7])+W_DO)>>W_DS;",
"VAR_3[VAR_7] -= (W_CM*(VAR_2[VAR_7] + VAR_4[VAR... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0
] | [
[
1
],
[
3
],
[
7,
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
25,
27,
29,
33,
35,
39,
41,
43,
45,
47,
51,
53,
55,
57,
61,
63,
65,
67,
69,
71,
73... |
16,134 | static int kvm_has_msr_star(CPUState *env)
{
static int has_msr_star;
int ret;
/* first time */
if (has_msr_star == 0) {
struct kvm_msr_list msr_list, *kvm_msr_list;
has_msr_star = -1;
/* Obtain MSR list from KVM. These are the MSRs that we must
*... | true | qemu | 6fb6d245546d3ae48c4cb764b3593e4739aa1364 | static int kvm_has_msr_star(CPUState *env)
{
static int has_msr_star;
int ret;
if (has_msr_star == 0) {
struct kvm_msr_list msr_list, *kvm_msr_list;
has_msr_star = -1;
msr_list.nmsrs = 0;
ret = kvm_ioctl(env->kvm_state, KVM_GET_MSR_INDE... | {
"code": [
" if (ret < 0)"
],
"line_no": [
31
]
} | static int FUNC_0(CPUState *VAR_0)
{
static int VAR_1;
int VAR_2;
if (VAR_1 == 0) {
struct VAR_4 VAR_3, *VAR_4;
VAR_1 = -1;
VAR_3.nmsrs = 0;
VAR_2 = kvm_ioctl(VAR_0->kvm_state, KVM_GET_MSR_INDEX_LIST, &VAR_3);
if (VAR_2 < 0)
... | [
"static int FUNC_0(CPUState *VAR_0)\n{",
"static int VAR_1;",
"int VAR_2;",
"if (VAR_1 == 0) {",
"struct VAR_4 VAR_3, *VAR_4;",
"VAR_1 = -1;",
"VAR_3.nmsrs = 0;",
"VAR_2 = kvm_ioctl(VAR_0->kvm_state, KVM_GET_MSR_INDEX_LIST, &VAR_3);",
"if (VAR_2 < 0)\nreturn 0;",
"VAR_4 = qemu_mallocz(MAX(1024, si... | [
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
13
],
[
15
],
[
19
],
[
27
],
[
29
],
[
31,
33
],
[
41,
43,
45
],
[
49
],
[
51
],
[
53
],
[
55
],
[
59
],
[
61
],
[
63
],
[
65
],
... |
16,136 | static CharDriverState *qemu_chr_open_stdio(ChardevStdio *opts)
{
CharDriverState *chr;
if (is_daemonized()) {
error_report("cannot use stdio with -daemonize");
return NULL;
}
old_fd0_flags = fcntl(0, F_GETFL);
tcgetattr (0, &oldtty);
qemu_set_nonblock(0);
atexit(... | true | qemu | c88930a6866e74953e931ae749781e98e486e5c8 | static CharDriverState *qemu_chr_open_stdio(ChardevStdio *opts)
{
CharDriverState *chr;
if (is_daemonized()) {
error_report("cannot use stdio with -daemonize");
return NULL;
}
old_fd0_flags = fcntl(0, F_GETFL);
tcgetattr (0, &oldtty);
qemu_set_nonblock(0);
atexit(... | {
"code": [
" tcgetattr (0, &oldtty);"
],
"line_no": [
19
]
} | static CharDriverState *FUNC_0(ChardevStdio *opts)
{
CharDriverState *chr;
if (is_daemonized()) {
error_report("cannot use stdio with -daemonize");
return NULL;
}
old_fd0_flags = fcntl(0, F_GETFL);
tcgetattr (0, &oldtty);
qemu_set_nonblock(0);
atexit(term_exit);
... | [
"static CharDriverState *FUNC_0(ChardevStdio *opts)\n{",
"CharDriverState *chr;",
"if (is_daemonized()) {",
"error_report(\"cannot use stdio with -daemonize\");",
"return NULL;",
"}",
"old_fd0_flags = fcntl(0, F_GETFL);",
"tcgetattr (0, &oldtty);",
"qemu_set_nonblock(0);",
"atexit(term_exit);",
... | [
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
43
],
[
45
]
] |
16,137 | void helper_vmexit(CPUX86State *env, uint32_t exit_code, uint64_t exit_info_1)
{
CPUState *cs = CPU(x86_env_get_cpu(env));
uint32_t int_ctl;
qemu_log_mask(CPU_LOG_TB_IN_ASM, "vmexit(%08x, %016" PRIx64 ", %016"
PRIx64 ", " TARGET_FMT_lx ")!\n",
exit_code, exit_info... | false | qemu | 7848c8d19f8556666df25044bbd5d8b29439c368 | void helper_vmexit(CPUX86State *env, uint32_t exit_code, uint64_t exit_info_1)
{
CPUState *cs = CPU(x86_env_get_cpu(env));
uint32_t int_ctl;
qemu_log_mask(CPU_LOG_TB_IN_ASM, "vmexit(%08x, %016" PRIx64 ", %016"
PRIx64 ", " TARGET_FMT_lx ")!\n",
exit_code, exit_info... | {
"code": [],
"line_no": []
} | void FUNC_0(CPUX86State *VAR_0, uint32_t VAR_1, uint64_t VAR_2)
{
CPUState *cs = CPU(x86_env_get_cpu(VAR_0));
uint32_t int_ctl;
qemu_log_mask(CPU_LOG_TB_IN_ASM, "vmexit(%08x, %016" PRIx64 ", %016"
PRIx64 ", " TARGET_FMT_lx ")!\n",
VAR_1, VAR_2,
... | [
"void FUNC_0(CPUX86State *VAR_0, uint32_t VAR_1, uint64_t VAR_2)\n{",
"CPUState *cs = CPU(x86_env_get_cpu(VAR_0));",
"uint32_t int_ctl;",
"qemu_log_mask(CPU_LOG_TB_IN_ASM, \"vmexit(%08x, %016\" PRIx64 \", %016\"\nPRIx64 \", \" TARGET_FMT_lx \")!\\n\",\nVAR_1, VAR_2,\nldq_phys(cs->as, VAR_0->vm_vmcb + offsetof... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
[
1,
3
],
[
5
],
[
7
],
[
11,
13,
15,
17,
19,
21
],
[
25
],
[
27,
29,
31
],
[
33
],
[
35
],
[
37,
39
],
[
41
],
[
47,
49
],
[
51,
53
],
[
55,
57
],
[
59,
61... |
16,139 | static void eval_coefs(int *coefs, const int *refl)
{
int buffer[10];
int *b1 = buffer;
int *b2 = coefs;
int x, y;
for (x=0; x < 10; x++) {
b1[x] = refl[x] << 4;
for (y=0; y < x; y++)
b1[y] = ((refl[x] * b2[x-y-1]) >> 12) + b2[y];
FFSWAP(int *, b1,... | false | FFmpeg | 6c9c8b06b32013c58101f27991eae251bf4eb485 | static void eval_coefs(int *coefs, const int *refl)
{
int buffer[10];
int *b1 = buffer;
int *b2 = coefs;
int x, y;
for (x=0; x < 10; x++) {
b1[x] = refl[x] << 4;
for (y=0; y < x; y++)
b1[y] = ((refl[x] * b2[x-y-1]) >> 12) + b2[y];
FFSWAP(int *, b1,... | {
"code": [],
"line_no": []
} | static void FUNC_0(int *VAR_0, const int *VAR_1)
{
int VAR_2[10];
int *VAR_3 = VAR_2;
int *VAR_4 = VAR_0;
int VAR_5, VAR_6;
for (VAR_5=0; VAR_5 < 10; VAR_5++) {
VAR_3[VAR_5] = VAR_1[VAR_5] << 4;
for (VAR_6=0; VAR_6 < VAR_5; VAR_6++)
VAR_3[VAR_6] = ((VAR_1[VAR... | [
"static void FUNC_0(int *VAR_0, const int *VAR_1)\n{",
"int VAR_2[10];",
"int *VAR_3 = VAR_2;",
"int *VAR_4 = VAR_0;",
"int VAR_5, VAR_6;",
"for (VAR_5=0; VAR_5 < 10; VAR_5++) {",
"VAR_3[VAR_5] = VAR_1[VAR_5] << 4;",
"for (VAR_6=0; VAR_6 < VAR_5; VAR_6++)",
"VAR_3[VAR_6] = ((VAR_1[VAR_5] * VAR_4[VAR... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
15
],
[
17
],
[
21
],
[
23
],
[
27
],
[
29
],
[
33
],
[
35
],
[
37
]
] |
16,141 | void kvmppc_hash64_free_pteg(uint64_t token)
{
struct kvm_get_htab_buf *htab_buf;
htab_buf = container_of((void *)(uintptr_t) token, struct kvm_get_htab_buf,
hpte);
g_free(htab_buf);
return;
}
| false | qemu | 1ad9f0a464fe78d30ee60b3629f7a825cf2fab13 | void kvmppc_hash64_free_pteg(uint64_t token)
{
struct kvm_get_htab_buf *htab_buf;
htab_buf = container_of((void *)(uintptr_t) token, struct kvm_get_htab_buf,
hpte);
g_free(htab_buf);
return;
}
| {
"code": [],
"line_no": []
} | void FUNC_0(uint64_t VAR_0)
{
struct kvm_get_htab_buf *VAR_1;
VAR_1 = container_of((void *)(uintptr_t) VAR_0, struct kvm_get_htab_buf,
hpte);
g_free(VAR_1);
return;
}
| [
"void FUNC_0(uint64_t VAR_0)\n{",
"struct kvm_get_htab_buf *VAR_1;",
"VAR_1 = container_of((void *)(uintptr_t) VAR_0, struct kvm_get_htab_buf,\nhpte);",
"g_free(VAR_1);",
"return;",
"}"
] | [
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9,
11
],
[
13
],
[
15
],
[
17
]
] |
16,142 | static void kvm_s390_flic_realize(DeviceState *dev, Error **errp)
{
S390FLICState *fs = S390_FLIC_COMMON(dev);
KVMS390FLICState *flic_state = KVM_S390_FLIC(dev);
struct kvm_create_device cd = {0};
struct kvm_device_attr test_attr = {0};
int ret;
Error *errp_local = NULL;
KVM_S390_F... | false | qemu | 3b00f702c236900cca403bdcbed48d59bfec0fba | static void kvm_s390_flic_realize(DeviceState *dev, Error **errp)
{
S390FLICState *fs = S390_FLIC_COMMON(dev);
KVMS390FLICState *flic_state = KVM_S390_FLIC(dev);
struct kvm_create_device cd = {0};
struct kvm_device_attr test_attr = {0};
int ret;
Error *errp_local = NULL;
KVM_S390_F... | {
"code": [],
"line_no": []
} | static void FUNC_0(DeviceState *VAR_0, Error **VAR_1)
{
S390FLICState *fs = S390_FLIC_COMMON(VAR_0);
KVMS390FLICState *flic_state = KVM_S390_FLIC(VAR_0);
struct kvm_create_device VAR_2 = {0};
struct kvm_device_attr VAR_3 = {0};
int VAR_4;
Error *errp_local = NULL;
KVM_S390_FLIC_GET... | [
"static void FUNC_0(DeviceState *VAR_0, Error **VAR_1)\n{",
"S390FLICState *fs = S390_FLIC_COMMON(VAR_0);",
"KVMS390FLICState *flic_state = KVM_S390_FLIC(VAR_0);",
"struct kvm_create_device VAR_2 = {0};",
"struct kvm_device_attr VAR_3 = {0};",
"int VAR_4;",
"Error *errp_local = NULL;",
"KVM_S390_FLIC_... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31,
33
],
[
35
],
[
37
],
[
39
],
[
43
],
[
45
],
[... |
16,143 | static void ide_cd_change_cb(void *opaque, bool load)
{
IDEState *s = opaque;
uint64_t nb_sectors;
s->tray_open = !load;
bdrv_get_geometry(s->bs, &nb_sectors);
s->nb_sectors = nb_sectors;
/*
* First indicate to the guest that a CD has been removed. That's
* done on the ne... | false | qemu | 4be746345f13e99e468c60acbd3a355e8183e3ce | static void ide_cd_change_cb(void *opaque, bool load)
{
IDEState *s = opaque;
uint64_t nb_sectors;
s->tray_open = !load;
bdrv_get_geometry(s->bs, &nb_sectors);
s->nb_sectors = nb_sectors;
s->cdrom_changed = 1;
s->events.new_media = true;
s->events.eject_req... | {
"code": [],
"line_no": []
} | static void FUNC_0(void *VAR_0, bool VAR_1)
{
IDEState *s = VAR_0;
uint64_t nb_sectors;
s->tray_open = !VAR_1;
bdrv_get_geometry(s->bs, &nb_sectors);
s->nb_sectors = nb_sectors;
s->cdrom_changed = 1;
s->events.new_media = true;
s->events.eject_request = fal... | [
"static void FUNC_0(void *VAR_0, bool VAR_1)\n{",
"IDEState *s = VAR_0;",
"uint64_t nb_sectors;",
"s->tray_open = !VAR_1;",
"bdrv_get_geometry(s->bs, &nb_sectors);",
"s->nb_sectors = nb_sectors;",
"s->cdrom_changed = 1;",
"s->events.new_media = true;",
"s->events.eject_request = false;",
"ide_set_... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
13
],
[
15
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
]
] |
16,144 | static int conditional_wait(DBDMA_channel *ch)
{
dbdma_cmd *current = &ch->current;
uint16_t wait;
uint16_t sel_mask, sel_value;
uint32_t status;
int cond;
DBDMA_DPRINTF("conditional_wait\n");
wait = le16_to_cpu(current->command) & WAIT_MASK;
switch(wait) {
case WAIT_... | false | qemu | ad674e53b5cce265fadafbde2c6a4f190345cd00 | static int conditional_wait(DBDMA_channel *ch)
{
dbdma_cmd *current = &ch->current;
uint16_t wait;
uint16_t sel_mask, sel_value;
uint32_t status;
int cond;
DBDMA_DPRINTF("conditional_wait\n");
wait = le16_to_cpu(current->command) & WAIT_MASK;
switch(wait) {
case WAIT_... | {
"code": [],
"line_no": []
} | static int FUNC_0(DBDMA_channel *VAR_0)
{
dbdma_cmd *current = &VAR_0->current;
uint16_t wait;
uint16_t sel_mask, sel_value;
uint32_t status;
int VAR_1;
DBDMA_DPRINTF("FUNC_0\n");
wait = le16_to_cpu(current->command) & WAIT_MASK;
switch(wait) {
case WAIT_NEVER:
... | [
"static int FUNC_0(DBDMA_channel *VAR_0)\n{",
"dbdma_cmd *current = &VAR_0->current;",
"uint16_t wait;",
"uint16_t sel_mask, sel_value;",
"uint32_t status;",
"int VAR_1;",
"DBDMA_DPRINTF(\"FUNC_0\\n\");",
"wait = le16_to_cpu(current->command) & WAIT_MASK;",
"switch(wait) {",
"case WAIT_NEVER:\nret... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
17
],
[
21
],
[
25
],
[
27,
29
],
[
31,
33
],
[
35
],
[
39
],
[
43
],
[
45
],
[
49
],
[
53
],
[
55,
57,
59
... |
16,145 | static void ide_atapi_cmd_read_dma_cb(void *opaque, int ret)
{
IDEState *s = opaque;
int data_offset, n;
if (ret < 0) {
ide_atapi_io_error(s, ret);
goto eot;
}
if (s->io_buffer_size > 0) {
/*
* For a cdrom read sector command (s->lba != -1),
*... | false | qemu | 4be746345f13e99e468c60acbd3a355e8183e3ce | static void ide_atapi_cmd_read_dma_cb(void *opaque, int ret)
{
IDEState *s = opaque;
int data_offset, n;
if (ret < 0) {
ide_atapi_io_error(s, ret);
goto eot;
}
if (s->io_buffer_size > 0) {
if (s->lba != -1) {
if (s->cd_sector_si... | {
"code": [],
"line_no": []
} | static void FUNC_0(void *VAR_0, int VAR_1)
{
IDEState *s = VAR_0;
int VAR_2, VAR_3;
if (VAR_1 < 0) {
ide_atapi_io_error(s, VAR_1);
goto eot;
}
if (s->io_buffer_size > 0) {
if (s->lba != -1) {
if (s->cd_sector_size == 2352) {
... | [
"static void FUNC_0(void *VAR_0, int VAR_1)\n{",
"IDEState *s = VAR_0;",
"int VAR_2, VAR_3;",
"if (VAR_1 < 0) {",
"ide_atapi_io_error(s, VAR_1);",
"goto eot;",
"}",
"if (s->io_buffer_size > 0) {",
"if (s->lba != -1) {",
"if (s->cd_sector_size == 2352) {",
"VAR_3 = 1;",
"cd_data_to_raw(s->io_bu... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
13
],
[
15
],
[
17
],
[
21
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49
],
[
51
],
[
53
],
[
55
],
[
57,
59
],
... |
16,146 | static int nbd_open(BlockDriverState *bs, QDict *options, int flags,
Error **errp)
{
BDRVNBDState *s = bs->opaque;
char *export = NULL;
int result, sock;
/* Pop the config into our state object. Exit if invalid. */
result = nbd_config(s, options, &export);
if (resul... | false | qemu | 77e8b9ca64e85d3d309f322410964b7852ec091e | static int nbd_open(BlockDriverState *bs, QDict *options, int flags,
Error **errp)
{
BDRVNBDState *s = bs->opaque;
char *export = NULL;
int result, sock;
result = nbd_config(s, options, &export);
if (result != 0) {
return result;
}
so... | {
"code": [],
"line_no": []
} | static int FUNC_0(BlockDriverState *VAR_0, QDict *VAR_1, int VAR_2,
Error **VAR_3)
{
BDRVNBDState *s = VAR_0->opaque;
char *VAR_4 = NULL;
int VAR_5, VAR_6;
VAR_5 = nbd_config(s, VAR_1, &VAR_4);
if (VAR_5 != 0) {
return VAR_5;
}
VAR_6 ... | [
"static int FUNC_0(BlockDriverState *VAR_0, QDict *VAR_1, int VAR_2,\nError **VAR_3)\n{",
"BDRVNBDState *s = VAR_0->opaque;",
"char *VAR_4 = NULL;",
"int VAR_5, VAR_6;",
"VAR_5 = nbd_config(s, VAR_1, &VAR_4);",
"if (VAR_5 != 0) {",
"return VAR_5;",
"}",
"VAR_6 = nbd_establish_connection(VAR_0);",
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
17
],
[
19
],
[
21
],
[
23
],
[
33
],
[
35
],
[
37
],
[
39
],
[
45
],
[
47
],
[
49
],
[
51
]
] |
16,148 | static int pl061_load(QEMUFile *f, void *opaque, int version_id)
{
pl061_state *s = (pl061_state *)opaque;
if (version_id != 1)
return -EINVAL;
s->locked = qemu_get_be32(f);
s->data = qemu_get_be32(f);
s->old_data = qemu_get_be32(f);
s->dir = qemu_get_be32(f);
s->isense = ... | false | qemu | a35faa94c8e8d851a1d07e17c98f4ab2202b8a38 | static int pl061_load(QEMUFile *f, void *opaque, int version_id)
{
pl061_state *s = (pl061_state *)opaque;
if (version_id != 1)
return -EINVAL;
s->locked = qemu_get_be32(f);
s->data = qemu_get_be32(f);
s->old_data = qemu_get_be32(f);
s->dir = qemu_get_be32(f);
s->isense = ... | {
"code": [],
"line_no": []
} | static int FUNC_0(QEMUFile *VAR_0, void *VAR_1, int VAR_2)
{
pl061_state *s = (pl061_state *)VAR_1;
if (VAR_2 != 1)
return -EINVAL;
s->locked = qemu_get_be32(VAR_0);
s->data = qemu_get_be32(VAR_0);
s->old_data = qemu_get_be32(VAR_0);
s->dir = qemu_get_be32(VAR_0);
s->isens... | [
"static int FUNC_0(QEMUFile *VAR_0, void *VAR_1, int VAR_2)\n{",
"pl061_state *s = (pl061_state *)VAR_1;",
"if (VAR_2 != 1)\nreturn -EINVAL;",
"s->locked = qemu_get_be32(VAR_0);",
"s->data = qemu_get_be32(VAR_0);",
"s->old_data = qemu_get_be32(VAR_0);",
"s->dir = qemu_get_be32(VAR_0);",
"s->isense = q... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7,
9
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[... |
16,149 | void pcie_host_mmcfg_map(PCIExpressHost *e, hwaddr addr,
uint32_t size)
{
assert(!(size & (size - 1))); /* power of 2 */
assert(size >= PCIE_MMCFG_SIZE_MIN);
assert(size <= PCIE_MMCFG_SIZE_MAX);
e->size = size;
memory_region_init_io(&e->mmio, OBJECT(e), &pcie_mm... | false | qemu | 27fb9688f9162515901ebf29e3879788fd326ea7 | void pcie_host_mmcfg_map(PCIExpressHost *e, hwaddr addr,
uint32_t size)
{
assert(!(size & (size - 1)));
assert(size >= PCIE_MMCFG_SIZE_MIN);
assert(size <= PCIE_MMCFG_SIZE_MAX);
e->size = size;
memory_region_init_io(&e->mmio, OBJECT(e), &pcie_mmcfg_ops, e,
... | {
"code": [],
"line_no": []
} | void FUNC_0(PCIExpressHost *VAR_0, hwaddr VAR_1,
uint32_t VAR_2)
{
assert(!(VAR_2 & (VAR_2 - 1)));
assert(VAR_2 >= PCIE_MMCFG_SIZE_MIN);
assert(VAR_2 <= PCIE_MMCFG_SIZE_MAX);
VAR_0->VAR_2 = VAR_2;
memory_region_init_io(&VAR_0->mmio, OBJECT(VAR_0), &pcie_mmcfg_o... | [
"void FUNC_0(PCIExpressHost *VAR_0, hwaddr VAR_1,\nuint32_t VAR_2)\n{",
"assert(!(VAR_2 & (VAR_2 - 1)));",
"assert(VAR_2 >= PCIE_MMCFG_SIZE_MIN);",
"assert(VAR_2 <= PCIE_MMCFG_SIZE_MAX);",
"VAR_0->VAR_2 = VAR_2;",
"memory_region_init_io(&VAR_0->mmio, OBJECT(VAR_0), &pcie_mmcfg_ops, VAR_0,\n\"pcie-mmcfg\",... | [
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15,
17
],
[
19
],
[
21
],
[
23
]
] |
16,150 | const char *small_strptime(const char *p, const char *fmt,
struct tm *dt)
{
int c, val;
for(;;) {
c = *fmt++;
if (c == '\0') {
return p;
} else if (c == '%') {
c = *fmt++;
switch(c) {
case 'H':
... | false | FFmpeg | add41decd94b2d3581a3715ba10f27168b8cdb1b | const char *small_strptime(const char *p, const char *fmt,
struct tm *dt)
{
int c, val;
for(;;) {
c = *fmt++;
if (c == '\0') {
return p;
} else if (c == '%') {
c = *fmt++;
switch(c) {
case 'H':
... | {
"code": [],
"line_no": []
} | const char *FUNC_0(const char *VAR_0, const char *VAR_1,
struct tm *VAR_2)
{
int VAR_3, VAR_4;
for(;;) {
VAR_3 = *VAR_1++;
if (VAR_3 == '\0') {
return VAR_0;
} else if (VAR_3 == '%') {
VAR_3 = *VAR_1++;
switch(VAR... | [
"const char *FUNC_0(const char *VAR_0, const char *VAR_1,\nstruct tm *VAR_2)\n{",
"int VAR_3, VAR_4;",
"for(;;) {",
"VAR_3 = *VAR_1++;",
"if (VAR_3 == '\\0') {",
"return VAR_0;",
"} else if (VAR_3 == '%') {",
"VAR_3 = *VAR_1++;",
"switch(VAR_3) {",
"case 'H':\nVAR_4 = date_get_num(&VAR_0, 0, 23, 2... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25,
27
],
[
29,
31
],
[
33
],
[
35
],
[
37,
39
],
[
41,
43
],
[
45
],
[
47
],
... |
16,151 | void ppc_set_irq (CPUState *env, int n_IRQ, int level)
{
if (level) {
env->pending_interrupts |= 1 << n_IRQ;
cpu_interrupt(env, CPU_INTERRUPT_HARD);
} else {
env->pending_interrupts &= ~(1 << n_IRQ);
if (env->pending_interrupts == 0)
cpu_reset_interrupt(env, C... | false | qemu | 00af685fc974e4941ef2d309a2e8818d311a370c | void ppc_set_irq (CPUState *env, int n_IRQ, int level)
{
if (level) {
env->pending_interrupts |= 1 << n_IRQ;
cpu_interrupt(env, CPU_INTERRUPT_HARD);
} else {
env->pending_interrupts &= ~(1 << n_IRQ);
if (env->pending_interrupts == 0)
cpu_reset_interrupt(env, C... | {
"code": [],
"line_no": []
} | void FUNC_0 (CPUState *VAR_0, int VAR_1, int VAR_2)
{
if (VAR_2) {
VAR_0->pending_interrupts |= 1 << VAR_1;
cpu_interrupt(VAR_0, CPU_INTERRUPT_HARD);
} else {
VAR_0->pending_interrupts &= ~(1 << VAR_1);
if (VAR_0->pending_interrupts == 0)
cpu_reset_interrupt(V... | [
"void FUNC_0 (CPUState *VAR_0, int VAR_1, int VAR_2)\n{",
"if (VAR_2) {",
"VAR_0->pending_interrupts |= 1 << VAR_1;",
"cpu_interrupt(VAR_0, CPU_INTERRUPT_HARD);",
"} else {",
"VAR_0->pending_interrupts &= ~(1 << VAR_1);",
"if (VAR_0->pending_interrupts == 0)\ncpu_reset_interrupt(VAR_0, CPU_INTERRUPT_HAR... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15,
17
],
[
19
],
[
21,
23
],
[
25,
27,
29
],
[
31
],
[
33,
35
]
] |
16,152 | static void fd_put_buffer(void *opaque, const uint8_t *buf,
int64_t pos, int size)
{
QEMUFileFD *s = opaque;
ssize_t len;
do {
len = write(s->fd, buf, size);
} while (len == -1 && errno == EINTR);
if (len == -1)
len = -errno;
/* When the ... | false | qemu | 871d2f079661323a7645b388eb5ae8d7eeb3117c | static void fd_put_buffer(void *opaque, const uint8_t *buf,
int64_t pos, int size)
{
QEMUFileFD *s = opaque;
ssize_t len;
do {
len = write(s->fd, buf, size);
} while (len == -1 && errno == EINTR);
if (len == -1)
len = -errno;
if (... | {
"code": [],
"line_no": []
} | static void FUNC_0(void *VAR_0, const uint8_t *VAR_1,
int64_t VAR_2, int VAR_3)
{
QEMUFileFD *s = VAR_0;
ssize_t len;
do {
len = write(s->fd, VAR_1, VAR_3);
} while (len == -1 && errno == EINTR);
if (len == -1)
len = -errno;
if (l... | [
"static void FUNC_0(void *VAR_0, const uint8_t *VAR_1,\nint64_t VAR_2, int VAR_3)\n{",
"QEMUFileFD *s = VAR_0;",
"ssize_t len;",
"do {",
"len = write(s->fd, VAR_1, VAR_3);",
"} while (len == -1 && errno == EINTR);",
"if (len == -1)\nlen = -errno;",
"if (len == -EAGAIN)\nqemu_set_fd_handler2(s->fd, NUL... | [
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
17
],
[
21,
23
],
[
31,
33
],
[
35
]
] |
16,153 | void laio_io_unplug(BlockDriverState *bs, void *aio_ctx, bool unplug)
{
struct qemu_laio_state *s = aio_ctx;
assert(s->io_q.plugged > 0 || !unplug);
if (unplug && --s->io_q.plugged > 0) {
return;
}
if (!s->io_q.blocked && !QSIMPLEQ_EMPTY(&s->io_q.pending)) {
ioq_submit(... | false | qemu | 6b98bd649520d07df4d1b7a0a54ac73bf178519c | void laio_io_unplug(BlockDriverState *bs, void *aio_ctx, bool unplug)
{
struct qemu_laio_state *s = aio_ctx;
assert(s->io_q.plugged > 0 || !unplug);
if (unplug && --s->io_q.plugged > 0) {
return;
}
if (!s->io_q.blocked && !QSIMPLEQ_EMPTY(&s->io_q.pending)) {
ioq_submit(... | {
"code": [],
"line_no": []
} | void FUNC_0(BlockDriverState *VAR_0, void *VAR_1, bool VAR_2)
{
struct qemu_laio_state *VAR_3 = VAR_1;
assert(VAR_3->io_q.plugged > 0 || !VAR_2);
if (VAR_2 && --VAR_3->io_q.plugged > 0) {
return;
}
if (!VAR_3->io_q.blocked && !QSIMPLEQ_EMPTY(&VAR_3->io_q.pending)) {
ioq... | [
"void FUNC_0(BlockDriverState *VAR_0, void *VAR_1, bool VAR_2)\n{",
"struct qemu_laio_state *VAR_3 = VAR_1;",
"assert(VAR_3->io_q.plugged > 0 || !VAR_2);",
"if (VAR_2 && --VAR_3->io_q.plugged > 0) {",
"return;",
"}",
"if (!VAR_3->io_q.blocked && !QSIMPLEQ_EMPTY(&VAR_3->io_q.pending)) {",
"ioq_submit(V... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
13
],
[
15
],
[
17
],
[
21
],
[
23
],
[
25
],
[
27
]
] |
16,154 | void acpi_pm1_cnt_init(ACPIREGS *ar, MemoryRegion *parent, uint8_t s4_val)
{
ar->pm1.cnt.s4_val = s4_val;
ar->wakeup.notify = acpi_notify_wakeup;
qemu_register_wakeup_notifier(&ar->wakeup);
memory_region_init_io(&ar->pm1.cnt.io, memory_region_owner(parent),
&acpi_pm_cnt_o... | false | qemu | 9a10bbb4e83b184faef6fa744396a6775283c0aa | void acpi_pm1_cnt_init(ACPIREGS *ar, MemoryRegion *parent, uint8_t s4_val)
{
ar->pm1.cnt.s4_val = s4_val;
ar->wakeup.notify = acpi_notify_wakeup;
qemu_register_wakeup_notifier(&ar->wakeup);
memory_region_init_io(&ar->pm1.cnt.io, memory_region_owner(parent),
&acpi_pm_cnt_o... | {
"code": [],
"line_no": []
} | void FUNC_0(ACPIREGS *VAR_0, MemoryRegion *VAR_1, uint8_t VAR_2)
{
VAR_0->pm1.cnt.VAR_2 = VAR_2;
VAR_0->wakeup.notify = acpi_notify_wakeup;
qemu_register_wakeup_notifier(&VAR_0->wakeup);
memory_region_init_io(&VAR_0->pm1.cnt.io, memory_region_owner(VAR_1),
&acpi_pm_cnt_op... | [
"void FUNC_0(ACPIREGS *VAR_0, MemoryRegion *VAR_1, uint8_t VAR_2)\n{",
"VAR_0->pm1.cnt.VAR_2 = VAR_2;",
"VAR_0->wakeup.notify = acpi_notify_wakeup;",
"qemu_register_wakeup_notifier(&VAR_0->wakeup);",
"memory_region_init_io(&VAR_0->pm1.cnt.io, memory_region_owner(VAR_1),\n&acpi_pm_cnt_ops, VAR_0, \"acpi-cnt\... | [
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11,
13
],
[
15
],
[
17
]
] |
16,156 | static void spapr_nmi(NMIState *n, int cpu_index, Error **errp)
{
CPUState *cs;
CPU_FOREACH(cs) {
async_run_on_cpu(cs, ppc_cpu_do_nmi_on_cpu, RUN_ON_CPU_NULL);
}
}
| false | qemu | 1c7ad77e56767fb36a7ccc954d304d4ac768b374 | static void spapr_nmi(NMIState *n, int cpu_index, Error **errp)
{
CPUState *cs;
CPU_FOREACH(cs) {
async_run_on_cpu(cs, ppc_cpu_do_nmi_on_cpu, RUN_ON_CPU_NULL);
}
}
| {
"code": [],
"line_no": []
} | static void FUNC_0(NMIState *VAR_0, int VAR_1, Error **VAR_2)
{
CPUState *cs;
CPU_FOREACH(cs) {
async_run_on_cpu(cs, ppc_cpu_do_nmi_on_cpu, RUN_ON_CPU_NULL);
}
}
| [
"static void FUNC_0(NMIState *VAR_0, int VAR_1, Error **VAR_2)\n{",
"CPUState *cs;",
"CPU_FOREACH(cs) {",
"async_run_on_cpu(cs, ppc_cpu_do_nmi_on_cpu, RUN_ON_CPU_NULL);",
"}",
"}"
] | [
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
],
[
13
],
[
15
]
] |
16,157 | static void do_test_validate_qmp_introspect(TestInputVisitorData *data,
const char *schema_json)
{
SchemaInfoList *schema = NULL;
Visitor *v;
v = validate_test_init_raw(data, schema_json);
visit_type_SchemaInfoList(v, NULL, &schema, &error_abort);
... | false | qemu | b3db211f3c80bb996a704d665fe275619f728bd4 | static void do_test_validate_qmp_introspect(TestInputVisitorData *data,
const char *schema_json)
{
SchemaInfoList *schema = NULL;
Visitor *v;
v = validate_test_init_raw(data, schema_json);
visit_type_SchemaInfoList(v, NULL, &schema, &error_abort);
... | {
"code": [],
"line_no": []
} | static void FUNC_0(TestInputVisitorData *VAR_0,
const char *VAR_1)
{
SchemaInfoList *schema = NULL;
Visitor *v;
v = validate_test_init_raw(VAR_0, VAR_1);
visit_type_SchemaInfoList(v, NULL, &schema, &error_abort);
g_assert(schema);
qapi_fr... | [
"static void FUNC_0(TestInputVisitorData *VAR_0,\nconst char *VAR_1)\n{",
"SchemaInfoList *schema = NULL;",
"Visitor *v;",
"v = validate_test_init_raw(VAR_0, VAR_1);",
"visit_type_SchemaInfoList(v, NULL, &schema, &error_abort);",
"g_assert(schema);",
"qapi_free_SchemaInfoList(schema);",
"}"
] | [
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
13
],
[
17
],
[
19
],
[
23
],
[
25
]
] |
16,158 | static int64_t coroutine_fn qcow_co_get_block_status(BlockDriverState *bs,
int64_t sector_num, int nb_sectors, int *pnum, BlockDriverState **file)
{
BDRVQcowState *s = bs->opaque;
int index_in_cluster, n;
uint64_t cluster_offset;
qemu_co_mutex_lock(&s->lock);
cluster_offset = get_cl... | false | qemu | d85f4222b4681da7ebf8a90b26e085a68fa2c55a | static int64_t coroutine_fn qcow_co_get_block_status(BlockDriverState *bs,
int64_t sector_num, int nb_sectors, int *pnum, BlockDriverState **file)
{
BDRVQcowState *s = bs->opaque;
int index_in_cluster, n;
uint64_t cluster_offset;
qemu_co_mutex_lock(&s->lock);
cluster_offset = get_cl... | {
"code": [],
"line_no": []
} | static int64_t VAR_0 qcow_co_get_block_status(BlockDriverState *bs,
int64_t sector_num, int nb_sectors, int *pnum, BlockDriverState **file)
{
BDRVQcowState *s = bs->opaque;
int index_in_cluster, n;
uint64_t cluster_offset;
qemu_co_mutex_lock(&s->lock);
cluster_offset = get_cluster_o... | [
"static int64_t VAR_0 qcow_co_get_block_status(BlockDriverState *bs,\nint64_t sector_num, int nb_sectors, int *pnum, BlockDriverState **file)\n{",
"BDRVQcowState *s = bs->opaque;",
"int index_in_cluster, n;",
"uint64_t cluster_offset;",
"qemu_co_mutex_lock(&s->lock);",
"cluster_offset = get_cluster_offset... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25,
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
... |
16,159 | int v9fs_co_symlink(V9fsState *s, V9fsFidState *fidp,
const char *oldpath, const char *newpath, gid_t gid)
{
int err;
FsCred cred;
cred_init(&cred);
cred.fc_uid = fidp->uid;
cred.fc_gid = gid;
cred.fc_mode = 0777;
v9fs_co_run_in_worker(
{
... | false | qemu | 02cb7f3a256517cbf3136caff2863fbafc57b540 | int v9fs_co_symlink(V9fsState *s, V9fsFidState *fidp,
const char *oldpath, const char *newpath, gid_t gid)
{
int err;
FsCred cred;
cred_init(&cred);
cred.fc_uid = fidp->uid;
cred.fc_gid = gid;
cred.fc_mode = 0777;
v9fs_co_run_in_worker(
{
... | {
"code": [],
"line_no": []
} | int FUNC_0(V9fsState *VAR_0, V9fsFidState *VAR_1,
const char *VAR_2, const char *VAR_3, gid_t VAR_4)
{
int VAR_5;
FsCred cred;
cred_init(&cred);
cred.fc_uid = VAR_1->uid;
cred.fc_gid = VAR_4;
cred.fc_mode = 0777;
v9fs_co_run_in_worker(
{
V... | [
"int FUNC_0(V9fsState *VAR_0, V9fsFidState *VAR_1,\nconst char *VAR_2, const char *VAR_3, gid_t VAR_4)\n{",
"int VAR_5;",
"FsCred cred;",
"cred_init(&cred);",
"cred.fc_uid = VAR_1->uid;",
"cred.fc_gid = VAR_4;",
"cred.fc_mode = 0777;",
"v9fs_co_run_in_worker(\n{",
"VAR_5 = VAR_0->ops->symlink(&VAR_0... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21,
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
]
] |
16,160 | static void cpu_x86_fill_host(x86_def_t *x86_cpu_def)
{
uint32_t eax = 0, ebx = 0, ecx = 0, edx = 0;
x86_cpu_def->name = "host";
host_cpuid(0x0, 0, &eax, &ebx, &ecx, &edx);
x86_cpu_def->level = eax;
x86_cpu_def->vendor1 = ebx;
x86_cpu_def->vendor2 = edx;
x86_cpu_def->vendor3 = ecx;... | false | qemu | 6e746f30558cb1331598575918c2a8808be2a75b | static void cpu_x86_fill_host(x86_def_t *x86_cpu_def)
{
uint32_t eax = 0, ebx = 0, ecx = 0, edx = 0;
x86_cpu_def->name = "host";
host_cpuid(0x0, 0, &eax, &ebx, &ecx, &edx);
x86_cpu_def->level = eax;
x86_cpu_def->vendor1 = ebx;
x86_cpu_def->vendor2 = edx;
x86_cpu_def->vendor3 = ecx;... | {
"code": [],
"line_no": []
} | static void FUNC_0(x86_def_t *VAR_0)
{
uint32_t eax = 0, ebx = 0, ecx = 0, edx = 0;
VAR_0->name = "host";
host_cpuid(0x0, 0, &eax, &ebx, &ecx, &edx);
VAR_0->level = eax;
VAR_0->vendor1 = ebx;
VAR_0->vendor2 = edx;
VAR_0->vendor3 = ecx;
host_cpuid(0x1, 0, &eax, &ebx, &ecx, &e... | [
"static void FUNC_0(x86_def_t *VAR_0)\n{",
"uint32_t eax = 0, ebx = 0, ecx = 0, edx = 0;",
"VAR_0->name = \"host\";",
"host_cpuid(0x0, 0, &eax, &ebx, &ecx, &edx);",
"VAR_0->level = eax;",
"VAR_0->vendor1 = ebx;",
"VAR_0->vendor2 = edx;",
"VAR_0->vendor3 = ecx;",
"host_cpuid(0x1, 0, &eax, &ebx, &ecx,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[
49... |
16,161 | static inline void mix_3f_2r_to_stereo(AC3DecodeContext *ctx)
{
int i;
float (*output)[256] = ctx->audio_block.block_output;
for (i = 0; i < 256; i++) {
output[1][i] += (output[2][i] + output[4][i]);
output[2][i] += (output[3][i] + output[5][i]);
}
memset(output[3], 0, size... | false | FFmpeg | 486637af8ef29ec215e0e0b7ecd3b5470f0e04e5 | static inline void mix_3f_2r_to_stereo(AC3DecodeContext *ctx)
{
int i;
float (*output)[256] = ctx->audio_block.block_output;
for (i = 0; i < 256; i++) {
output[1][i] += (output[2][i] + output[4][i]);
output[2][i] += (output[3][i] + output[5][i]);
}
memset(output[3], 0, size... | {
"code": [],
"line_no": []
} | static inline void FUNC_0(AC3DecodeContext *VAR_0)
{
int VAR_1;
float (*VAR_2)[256] = VAR_0->audio_block.block_output;
for (VAR_1 = 0; VAR_1 < 256; VAR_1++) {
VAR_2[1][VAR_1] += (VAR_2[2][VAR_1] + VAR_2[4][VAR_1]);
VAR_2[2][VAR_1] += (VAR_2[3][VAR_1] + VAR_2[5][VAR_1]);
}
m... | [
"static inline void FUNC_0(AC3DecodeContext *VAR_0)\n{",
"int VAR_1;",
"float (*VAR_2)[256] = VAR_0->audio_block.block_output;",
"for (VAR_1 = 0; VAR_1 < 256; VAR_1++) {",
"VAR_2[1][VAR_1] += (VAR_2[2][VAR_1] + VAR_2[4][VAR_1]);",
"VAR_2[2][VAR_1] += (VAR_2[3][VAR_1] + VAR_2[5][VAR_1]);",
"}",
"memset... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
]
] |
16,162 | static int vmdk_open_desc_file(BlockDriverState *bs, int flags, char *buf,
Error **errp)
{
int ret;
char ct[128];
BDRVVmdkState *s = bs->opaque;
if (vmdk_parse_description(buf, "createType", ct, sizeof(ct))) {
error_setg(errp, "invalid VMDK image descripto... | false | qemu | a646836784a0fc50fee6f9a0d3fb968289714128 | static int vmdk_open_desc_file(BlockDriverState *bs, int flags, char *buf,
Error **errp)
{
int ret;
char ct[128];
BDRVVmdkState *s = bs->opaque;
if (vmdk_parse_description(buf, "createType", ct, sizeof(ct))) {
error_setg(errp, "invalid VMDK image descripto... | {
"code": [],
"line_no": []
} | static int FUNC_0(BlockDriverState *VAR_0, int VAR_1, char *VAR_2,
Error **VAR_3)
{
int VAR_4;
char VAR_5[128];
BDRVVmdkState *s = VAR_0->opaque;
if (vmdk_parse_description(VAR_2, "createType", VAR_5, sizeof(VAR_5))) {
error_setg(VAR_3, "invalid VMDK image... | [
"static int FUNC_0(BlockDriverState *VAR_0, int VAR_1, char *VAR_2,\nError **VAR_3)\n{",
"int VAR_4;",
"char VAR_5[128];",
"BDRVVmdkState *s = VAR_0->opaque;",
"if (vmdk_parse_description(VAR_2, \"createType\", VAR_5, sizeof(VAR_5))) {",
"error_setg(VAR_3, \"invalid VMDK image descriptor\");",
"VAR_4 = ... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25,
27,
29,
31,
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[... |
16,165 | static void tcg_out_qemu_ld (TCGContext *s, const TCGArg *args, int opc)
{
int addr_reg, data_reg, data_reg2, r0, r1, rbase, mem_index, s_bits, bswap;
#ifdef CONFIG_SOFTMMU
int r2;
void *label1_ptr, *label2_ptr;
#endif
#if TARGET_LONG_BITS == 64
int addr_reg2;
#endif
data_reg = *args++;
... | false | qemu | 355b194369d02df7a97d554eef2a9cffe98d736f | static void tcg_out_qemu_ld (TCGContext *s, const TCGArg *args, int opc)
{
int addr_reg, data_reg, data_reg2, r0, r1, rbase, mem_index, s_bits, bswap;
#ifdef CONFIG_SOFTMMU
int r2;
void *label1_ptr, *label2_ptr;
#endif
#if TARGET_LONG_BITS == 64
int addr_reg2;
#endif
data_reg = *args++;
... | {
"code": [],
"line_no": []
} | static void FUNC_0 (TCGContext *VAR_0, const TCGArg *VAR_1, int VAR_2)
{
int VAR_3, VAR_4, VAR_5, VAR_6, VAR_7, VAR_8, VAR_9, VAR_10, VAR_11;
#ifdef CONFIG_SOFTMMU
int r2;
void *label1_ptr, *label2_ptr;
#endif
#if TARGET_LONG_BITS == 64
int addr_reg2;
#endif
VAR_4 = *VAR_1++;
if (VA... | [
"static void FUNC_0 (TCGContext *VAR_0, const TCGArg *VAR_1, int VAR_2)\n{",
"int VAR_3, VAR_4, VAR_5, VAR_6, VAR_7, VAR_8, VAR_9, VAR_10, VAR_11;",
"#ifdef CONFIG_SOFTMMU\nint r2;",
"void *label1_ptr, *label2_ptr;",
"#endif\n#if TARGET_LONG_BITS == 64\nint addr_reg2;",
"#endif\nVAR_4 = *VAR_1++;",
"if ... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
[
1,
3
],
[
5
],
[
7,
9
],
[
11
],
[
13,
15,
17
],
[
19,
23
],
[
25,
27
],
[
29,
31
],
[
33
],
[
35,
37
],
[
39,
41
],
[
43
],
[
47,
49
],
[
51
],
[
53
],
[... |
16,166 | int32_t helper_fstoi(CPUSPARCState *env, float32 src)
{
int32_t ret;
clear_float_exceptions(env);
ret = float32_to_int32_round_to_zero(src, &env->fp_status);
check_ieee_exceptions(env);
return ret;
}
| false | qemu | 7385aed20db5d83979f683b9d0048674411e963c | int32_t helper_fstoi(CPUSPARCState *env, float32 src)
{
int32_t ret;
clear_float_exceptions(env);
ret = float32_to_int32_round_to_zero(src, &env->fp_status);
check_ieee_exceptions(env);
return ret;
}
| {
"code": [],
"line_no": []
} | int32_t FUNC_0(CPUSPARCState *env, float32 src)
{
int32_t ret;
clear_float_exceptions(env);
ret = float32_to_int32_round_to_zero(src, &env->fp_status);
check_ieee_exceptions(env);
return ret;
}
| [
"int32_t FUNC_0(CPUSPARCState *env, float32 src)\n{",
"int32_t ret;",
"clear_float_exceptions(env);",
"ret = float32_to_int32_round_to_zero(src, &env->fp_status);",
"check_ieee_exceptions(env);",
"return ret;",
"}"
] | [
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
]
] |
16,167 | static void version(void)
{
printf("qemu-" TARGET_ARCH " version " QEMU_VERSION QEMU_PKGVERSION
", Copyright (c) 2003-2008 Fabrice Bellard\n");
}
| false | qemu | fc9c54124d134dbd76338a92a91804dab2df8166 | static void version(void)
{
printf("qemu-" TARGET_ARCH " version " QEMU_VERSION QEMU_PKGVERSION
", Copyright (c) 2003-2008 Fabrice Bellard\n");
}
| {
"code": [],
"line_no": []
} | static void FUNC_0(void)
{
printf("qemu-" TARGET_ARCH " FUNC_0 " QEMU_VERSION QEMU_PKGVERSION
", Copyright (c) 2003-2008 Fabrice Bellard\n");
}
| [
"static void FUNC_0(void)\n{",
"printf(\"qemu-\" TARGET_ARCH \" FUNC_0 \" QEMU_VERSION QEMU_PKGVERSION\n\", Copyright (c) 2003-2008 Fabrice Bellard\\n\");",
"}"
] | [
0,
0,
0
] | [
[
1,
3
],
[
5,
7
],
[
9
]
] |
16,169 | static void raw_aio_flush_io_queue(BlockDriverState *bs)
{
#ifdef CONFIG_LINUX_AIO
BDRVRawState *s = bs->opaque;
if (s->use_aio) {
laio_io_unplug(bs, s->aio_ctx, false);
}
#endif
}
| false | qemu | 6b98bd649520d07df4d1b7a0a54ac73bf178519c | static void raw_aio_flush_io_queue(BlockDriverState *bs)
{
#ifdef CONFIG_LINUX_AIO
BDRVRawState *s = bs->opaque;
if (s->use_aio) {
laio_io_unplug(bs, s->aio_ctx, false);
}
#endif
}
| {
"code": [],
"line_no": []
} | static void FUNC_0(BlockDriverState *VAR_0)
{
#ifdef CONFIG_LINUX_AIO
BDRVRawState *s = VAR_0->opaque;
if (s->use_aio) {
laio_io_unplug(VAR_0, s->aio_ctx, false);
}
#endif
}
| [
"static void FUNC_0(BlockDriverState *VAR_0)\n{",
"#ifdef CONFIG_LINUX_AIO\nBDRVRawState *s = VAR_0->opaque;",
"if (s->use_aio) {",
"laio_io_unplug(VAR_0, s->aio_ctx, false);",
"}",
"#endif\n}"
] | [
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5,
7
],
[
9
],
[
11
],
[
13
],
[
15,
17
]
] |
16,170 | static inline void RENAME(bgr24ToUV)(uint8_t *dstU, uint8_t *dstV, uint8_t *src1, uint8_t *src2, long width)
{
#ifdef HAVE_MMX
asm volatile(
"mov %3, %%"REG_a" \n\t"
"movq "MANGLE(w1111)", %%mm5 \n\t"
"movq "MANGLE(bgr2UCoeff)", %%mm6 \n\t"
"pxor %%mm7, %%mm7 \n\t"
"lea (%%"REG_a", %%"REG_a", 2),... | true | FFmpeg | 2da0d70d5eebe42f9fcd27ee554419ebe2a5da06 | static inline void RENAME(bgr24ToUV)(uint8_t *dstU, uint8_t *dstV, uint8_t *src1, uint8_t *src2, long width)
{
#ifdef HAVE_MMX
asm volatile(
"mov %3, %%"REG_a" \n\t"
"movq "MANGLE(w1111)", %%mm5 \n\t"
"movq "MANGLE(bgr2UCoeff)", %%mm6 \n\t"
"pxor %%mm7, %%mm7 \n\t"
"lea (%%"REG_a", %%"REG_a", 2),... | {
"code": [
"\t\t\"pxor %%mm7, %%mm7\t\t\\n\\t\"",
"\t\t\"pxor %%mm7, %%mm7\t\t\\n\\t\"",
"\t\t\"pxor %%mm7, %%mm7\t\t\\n\\t\"",
"\t\t\"pxor %%mm7, %%mm7\t\t\\n\\t\"",
"\tasm volatile(",
"\t);",
"\tint i;",
"#endif",
"#endif",
"#endif",
"#endif",
"#endif",
"\tint i;... | static inline void FUNC_0(bgr24ToUV)(uint8_t *dstU, uint8_t *dstV, uint8_t *src1, uint8_t *src2, long width)
{
#ifdef HAVE_MMX
asm volatile(
"mov %3, %%"REG_a" \n\t"
"movq "MANGLE(w1111)", %%mm5 \n\t"
"movq "MANGLE(bgr2UCoeff)", %%mm6 \n\t"
"pxor %%mm7, %%mm7 \n\t"
"lea (%%"REG_a", %%"REG_a", 2),... | [
"static inline void FUNC_0(bgr24ToUV)(uint8_t *dstU, uint8_t *dstV, uint8_t *src1, uint8_t *src2, long width)\n{",
"#ifdef HAVE_MMX\nasm volatile(\n\"mov %3, %%\"REG_a\"\t\t\\n\\t\"\n\"movq \"MANGLE(w1111)\", %%mm5\t\t\\n\\t\"\n\"movq \"MANGLE(bgr2UCoeff)\", %%mm6\t\t\\n\\t\"\n\"pxor %%mm7, %%mm7\t\t\\n\\t\"\n\"l... | [
0,
1,
1,
1,
0,
1,
1,
1,
1,
1,
0,
1,
0
] | [
[
1,
3
],
[
5,
7,
9,
11,
13,
15,
17,
19,
21,
23,
25,
27,
29,
31,
33,
35,
37,
39,
41,
43,
45,
47,
49,
51,
53,
55,
57,
59,
61,
63,
65,
67,
69,
71,
73,
75,
77,... |
16,171 | static void test_ivshmem_server(void)
{
IVState state1, state2, *s1, *s2;
ServerThread thread;
IvshmemServer server;
int ret, vm1, vm2;
int nvectors = 2;
guint64 end_time = g_get_monotonic_time() + 5 * G_TIME_SPAN_SECOND;
memset(tmpshmem, 0x42, TMPSHMSIZE);
ret = ivshmem_serve... | true | qemu | 1760048a5d21bacf0e4838da2f61b2d8db7d2866 | static void test_ivshmem_server(void)
{
IVState state1, state2, *s1, *s2;
ServerThread thread;
IvshmemServer server;
int ret, vm1, vm2;
int nvectors = 2;
guint64 end_time = g_get_monotonic_time() + 5 * G_TIME_SPAN_SECOND;
memset(tmpshmem, 0x42, TMPSHMSIZE);
ret = ivshmem_serve... | {
"code": [
" qtest_quit(s1->qtest);",
" qtest_quit(s2->qtest);",
" qtest_quit(s2->qtest);",
" qtest_quit(s1->qtest);"
],
"line_no": [
151,
149,
149,
151
]
} | static void FUNC_0(void)
{
IVState state1, state2, *s1, *s2;
ServerThread thread;
IvshmemServer server;
int VAR_0, VAR_1, VAR_2;
int VAR_3 = 2;
guint64 end_time = g_get_monotonic_time() + 5 * G_TIME_SPAN_SECOND;
memset(tmpshmem, 0x42, TMPSHMSIZE);
VAR_0 = ivshmem_server_init(&... | [
"static void FUNC_0(void)\n{",
"IVState state1, state2, *s1, *s2;",
"ServerThread thread;",
"IvshmemServer server;",
"int VAR_0, VAR_1, VAR_2;",
"int VAR_3 = 2;",
"guint64 end_time = g_get_monotonic_time() + 5 * G_TIME_SPAN_SECOND;",
"memset(tmpshmem, 0x42, TMPSHMSIZE);",
"VAR_0 = ivshmem_server_ini... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
19
],
[
21,
23,
25
],
[
27
],
[
31
],
[
33
],
[
37
],
[
39
],
[
41
],
[
43
],
[
47
],
[
49
],
[
53
... |
16,172 | static int escape124_decode_frame(AVCodecContext *avctx,
void *data, int *got_frame,
AVPacket *avpkt)
{
int buf_size = avpkt->size;
Escape124Context *s = avctx->priv_data;
AVFrame *frame = data;
GetBitContext gb;
unsigned frame_flag... | true | FFmpeg | da617408c80afd2ea67a175fabc0ba546b9b04bc | static int escape124_decode_frame(AVCodecContext *avctx,
void *data, int *got_frame,
AVPacket *avpkt)
{
int buf_size = avpkt->size;
Escape124Context *s = avctx->priv_data;
AVFrame *frame = data;
GetBitContext gb;
unsigned frame_flag... | {
"code": [],
"line_no": []
} | static int FUNC_0(AVCodecContext *VAR_0,
void *VAR_1, int *VAR_2,
AVPacket *VAR_3)
{
int VAR_4 = VAR_3->size;
Escape124Context *s = VAR_0->priv_data;
AVFrame *frame = VAR_1;
GetBitContext gb;
unsigned VAR_5, VAR_6;
unsigned VAR_... | [
"static int FUNC_0(AVCodecContext *VAR_0,\nvoid *VAR_1, int *VAR_2,\nAVPacket *VAR_3)\n{",
"int VAR_4 = VAR_3->size;",
"Escape124Context *s = VAR_0->priv_data;",
"AVFrame *frame = VAR_1;",
"GetBitContext gb;",
"unsigned VAR_5, VAR_6;",
"unsigned VAR_7;",
"unsigned VAR_8, VAR_9 = 1,\nVAR_10 = 0,\nVAR_1... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
[
1,
2,
3,
4
],
[
5
],
[
6
],
[
7
],
[
8
],
[
9
],
[
10
],
[
11,
12,
13
],
[
14
],
[
15
],
[
16
],
[
17,
18
],
[
21,
22
],
[
23
],
[
24
],
[
27
],
[
28,
... |
16,173 | DeviceState *qdev_create(BusState *bus, const char *name)
{
DeviceState *dev;
dev = qdev_try_create(bus, name);
if (!dev) {
hw_error("Unknown device '%s' for bus '%s'\n", name, bus->info->name);
}
return dev;
}
| true | qemu | e92714c71a2f50b8420126e952cadb653fa0ef93 | DeviceState *qdev_create(BusState *bus, const char *name)
{
DeviceState *dev;
dev = qdev_try_create(bus, name);
if (!dev) {
hw_error("Unknown device '%s' for bus '%s'\n", name, bus->info->name);
}
return dev;
}
| {
"code": [
" hw_error(\"Unknown device '%s' for bus '%s'\\n\", name, bus->info->name);"
],
"line_no": [
13
]
} | DeviceState *FUNC_0(BusState *bus, const char *name)
{
DeviceState *dev;
dev = qdev_try_create(bus, name);
if (!dev) {
hw_error("Unknown device '%s' for bus '%s'\n", name, bus->info->name);
}
return dev;
}
| [
"DeviceState *FUNC_0(BusState *bus, const char *name)\n{",
"DeviceState *dev;",
"dev = qdev_try_create(bus, name);",
"if (!dev) {",
"hw_error(\"Unknown device '%s' for bus '%s'\\n\", name, bus->info->name);",
"}",
"return dev;",
"}"
] | [
0,
0,
0,
0,
1,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
],
[
13
],
[
15
],
[
19
],
[
21
]
] |
16,174 | static void quantize_and_encode_band_cost_SQUAD_mips(struct AACEncContext *s,
PutBitContext *pb, const float *in, float *out,
const float *scaled, int size, int scale_idx,
... | true | FFmpeg | 01ecb7172b684f1c4b3e748f95c5a9a494ca36ec | static void quantize_and_encode_band_cost_SQUAD_mips(struct AACEncContext *s,
PutBitContext *pb, const float *in, float *out,
const float *scaled, int size, int scale_idx,
... | {
"code": [
" int *bits, const float ROUNDING)",
" if (out) {",
" vec = &p_vec[curidx*4];",
" out[i+0] = vec[0] * IQ;",
" out[i+1] = vec[1] * IQ;",
" out[i+2] = vec[2] * IQ;",
" out... | static void FUNC_0(struct AACEncContext *VAR_0,
PutBitContext *VAR_1, const float *VAR_2, float *VAR_3,
const float *VAR_4, int VAR_5, int VAR_6,
int VAR_7, c... | [
"static void FUNC_0(struct AACEncContext *VAR_0,\nPutBitContext *VAR_1, const float *VAR_2, float *VAR_3,\nconst float *VAR_4, int VAR_5, int VAR_6,\nint VAR_7, const float VAR_8, const float VAR_9,\nint *VAR_10, const float VAR_11)\n{",
"const float VAR_12 = ff_aac_pow34sf_tab[POW_SF2_ZERO - VAR_6 + SCALE_ONE_PO... | [
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
1,
1,
1,
1,
1,
0,
0,
0
] | [
[
1,
3,
5,
7,
9,
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
23
],
[
25
],
[
27
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
47
],
[
49
],
[
51
... |
16,175 | static void vhost_begin(MemoryListener *listener)
{
}
| true | qemu | af60314291af3cabda18d27f928b0e0ff899cc76 | static void vhost_begin(MemoryListener *listener)
{
}
| {
"code": [
"static void vhost_begin(MemoryListener *listener)"
],
"line_no": [
1
]
} | static void FUNC_0(MemoryListener *VAR_0)
{
}
| [
"static void FUNC_0(MemoryListener *VAR_0)\n{",
"}"
] | [
1,
0
] | [
[
1,
3
],
[
5
]
] |
16,176 | void ff_tls_deinit(void)
{
#if CONFIG_TLS_OPENSSL_PROTOCOL
ff_openssl_deinit();
#endif
#if CONFIG_TLS_GNUTLS_PROTOCOL
ff_gnutls_deinit();
#endif
}
| true | FFmpeg | 61cec5adaacb358783c18aa07362f15824c1b274 | void ff_tls_deinit(void)
{
#if CONFIG_TLS_OPENSSL_PROTOCOL
ff_openssl_deinit();
#endif
#if CONFIG_TLS_GNUTLS_PROTOCOL
ff_gnutls_deinit();
#endif
}
| {
"code": [
"#if CONFIG_TLS_OPENSSL_PROTOCOL",
"#if CONFIG_TLS_GNUTLS_PROTOCOL",
"#if CONFIG_TLS_OPENSSL_PROTOCOL",
"#if CONFIG_TLS_GNUTLS_PROTOCOL"
],
"line_no": [
5,
11,
5,
11
]
} | void FUNC_0(void)
{
#if CONFIG_TLS_OPENSSL_PROTOCOL
ff_openssl_deinit();
#endif
#if CONFIG_TLS_GNUTLS_PROTOCOL
ff_gnutls_deinit();
#endif
}
| [
"void FUNC_0(void)\n{",
"#if CONFIG_TLS_OPENSSL_PROTOCOL\nff_openssl_deinit();",
"#endif\n#if CONFIG_TLS_GNUTLS_PROTOCOL\nff_gnutls_deinit();",
"#endif\n}"
] | [
0,
1,
1,
0
] | [
[
1,
3
],
[
5,
7
],
[
9,
11,
13
],
[
15,
17
]
] |
16,178 | static void xbr2x(AVFrame * input, AVFrame * output, const uint32_t * r2y)
{
int x,y;
int next_line = output->linesize[0]>>2;
for (y = 0; y < input->height; y++) {
uint32_t pprev;
uint32_t pprev2;
uint32_t * E = (uint32_t *)(output->data[0] + y * output->linesize[0] * 2)... | true | FFmpeg | e0704840404381c7b976a35db4004deca4495a22 | static void xbr2x(AVFrame * input, AVFrame * output, const uint32_t * r2y)
{
int x,y;
int next_line = output->linesize[0]>>2;
for (y = 0; y < input->height; y++) {
uint32_t pprev;
uint32_t pprev2;
uint32_t * E = (uint32_t *)(output->data[0] + y * output->linesize[0] * 2)... | {
"code": [
" uint32_t pprev;",
" uint32_t pprev2;",
" pprev = pprev2 = 2;",
" uint32_t C1 = 0;",
" uint32_t PC = 0;",
" uint32_t PF = 0;",
" uint32_t PI = 0;",
" uint32_t I5 = 0;",
" uint32_t C4... | static void FUNC_0(AVFrame * VAR_0, AVFrame * VAR_1, const uint32_t * VAR_2)
{
int VAR_3,VAR_4;
int VAR_5 = VAR_1->linesize[0]>>2;
for (VAR_4 = 0; VAR_4 < VAR_0->height; VAR_4++) {
uint32_t pprev;
uint32_t pprev2;
uint32_t * E = (uint32_t *)(VAR_1->data[0] + VAR_4 * VAR_... | [
"static void FUNC_0(AVFrame * VAR_0, AVFrame * VAR_1, const uint32_t * VAR_2)\n{",
"int VAR_3,VAR_4;",
"int VAR_5 = VAR_1->linesize[0]>>2;",
"for (VAR_4 = 0; VAR_4 < VAR_0->height; VAR_4++) {",
"uint32_t pprev;",
"uint32_t pprev2;",
"uint32_t * E = (uint32_t *)(VAR_1->data[0] + VAR_4 * VAR_1->linesize[0... | [
0,
0,
0,
0,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
1,
1,
1,
1,
1,
1... | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
15
],
[
17
],
[
21
],
[
27
],
[
31
],
[
35
],
[
39
],
[
43
],
[
47
],
[
49
],
[
51
],
[
53
],
[
55
],
[
57
],
[
61
],
[
63... |
16,179 | static inline int32_t mipsdsp_sat_add_i32(int32_t a, int32_t b,
CPUMIPSState *env)
{
int32_t tempI;
tempI = a + b;
if (MIPSDSP_OVERFLOW(a, b, tempI, 0x80000000)) {
if (a > 0) {
tempI = 0x7FFFFFFF;
} else {
tempI =... | true | qemu | 20c334a797bf46a4ee59a6e42be6d5e7c3cda585 | static inline int32_t mipsdsp_sat_add_i32(int32_t a, int32_t b,
CPUMIPSState *env)
{
int32_t tempI;
tempI = a + b;
if (MIPSDSP_OVERFLOW(a, b, tempI, 0x80000000)) {
if (a > 0) {
tempI = 0x7FFFFFFF;
} else {
tempI =... | {
"code": [
" if (MIPSDSP_OVERFLOW(a, b, tempI, 0x80000000)) {",
" if (a > 0) {",
" if (a > 0) {"
],
"line_no": [
15,
17,
17
]
} | static inline int32_t FUNC_0(int32_t a, int32_t b,
CPUMIPSState *env)
{
int32_t tempI;
tempI = a + b;
if (MIPSDSP_OVERFLOW(a, b, tempI, 0x80000000)) {
if (a > 0) {
tempI = 0x7FFFFFFF;
} else {
tempI = 0x80000000;
... | [
"static inline int32_t FUNC_0(int32_t a, int32_t b,\nCPUMIPSState *env)\n{",
"int32_t tempI;",
"tempI = a + b;",
"if (MIPSDSP_OVERFLOW(a, b, tempI, 0x80000000)) {",
"if (a > 0) {",
"tempI = 0x7FFFFFFF;",
"} else {",
"tempI = 0x80000000;",
"}",
"set_DSPControl_overflow_flag(1, 20, env);",
"}",
... | [
0,
0,
0,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
11
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
33
],
[
35
]
] |
16,180 | CharDriverState *uart_hci_init(qemu_irq wakeup)
{
struct csrhci_s *s = (struct csrhci_s *)
g_malloc0(sizeof(struct csrhci_s));
s->chr.opaque = s;
s->chr.chr_write = csrhci_write;
s->chr.chr_ioctl = csrhci_ioctl;
s->hci = qemu_next_hci();
s->hci->opaque = s;
s->hci->... | true | qemu | 456d60692310e7ac25cf822cc1e98192ad636ece | CharDriverState *uart_hci_init(qemu_irq wakeup)
{
struct csrhci_s *s = (struct csrhci_s *)
g_malloc0(sizeof(struct csrhci_s));
s->chr.opaque = s;
s->chr.chr_write = csrhci_write;
s->chr.chr_ioctl = csrhci_ioctl;
s->hci = qemu_next_hci();
s->hci->opaque = s;
s->hci->... | {
"code": [],
"line_no": []
} | CharDriverState *FUNC_0(qemu_irq wakeup)
{
struct csrhci_s *VAR_0 = (struct csrhci_s *)
g_malloc0(sizeof(struct csrhci_s));
VAR_0->chr.opaque = VAR_0;
VAR_0->chr.chr_write = csrhci_write;
VAR_0->chr.chr_ioctl = csrhci_ioctl;
VAR_0->hci = qemu_next_hci();
VAR_0->hci->opaq... | [
"CharDriverState *FUNC_0(qemu_irq wakeup)\n{",
"struct csrhci_s *VAR_0 = (struct csrhci_s *)\ng_malloc0(sizeof(struct csrhci_s));",
"VAR_0->chr.opaque = VAR_0;",
"VAR_0->chr.chr_write = csrhci_write;",
"VAR_0->chr.chr_ioctl = csrhci_ioctl;",
"VAR_0->hci = qemu_next_hci();",
"VAR_0->hci->opaque = VAR_0;"... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5,
7
],
[
11
],
[
13
],
[
15
],
[
20
],
[
22
],
[
24
],
[
26
],
[
30
],
[
32
],
[
34
],
[
38
],
[
40
]
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.