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 |
|---|---|---|---|---|---|---|---|---|---|---|
4,545 | static void isa_mmio_writeb (void *opaque, target_phys_addr_t addr,
uint32_t val)
{
cpu_outb(addr & IOPORTS_MASK, val);
}
| false | qemu | a8170e5e97ad17ca169c64ba87ae2f53850dab4c | static void isa_mmio_writeb (void *opaque, target_phys_addr_t addr,
uint32_t val)
{
cpu_outb(addr & IOPORTS_MASK, val);
}
| {
"code": [],
"line_no": []
} | static void FUNC_0 (void *VAR_0, target_phys_addr_t VAR_1,
uint32_t VAR_2)
{
cpu_outb(VAR_1 & IOPORTS_MASK, VAR_2);
}
| [
"static void FUNC_0 (void *VAR_0, target_phys_addr_t VAR_1,\nuint32_t VAR_2)\n{",
"cpu_outb(VAR_1 & IOPORTS_MASK, VAR_2);",
"}"
] | [
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
]
] |
4,546 | static void kill_channel(DBDMA_channel *ch)
{
DBDMA_DPRINTF("kill_channel\n");
ch->regs[DBDMA_STATUS] |= cpu_to_be32(DEAD);
ch->regs[DBDMA_STATUS] &= cpu_to_be32(~ACTIVE);
qemu_irq_raise(ch->irq);
}
| false | qemu | ad674e53b5cce265fadafbde2c6a4f190345cd00 | static void kill_channel(DBDMA_channel *ch)
{
DBDMA_DPRINTF("kill_channel\n");
ch->regs[DBDMA_STATUS] |= cpu_to_be32(DEAD);
ch->regs[DBDMA_STATUS] &= cpu_to_be32(~ACTIVE);
qemu_irq_raise(ch->irq);
}
| {
"code": [],
"line_no": []
} | static void FUNC_0(DBDMA_channel *VAR_0)
{
DBDMA_DPRINTF("FUNC_0\n");
VAR_0->regs[DBDMA_STATUS] |= cpu_to_be32(DEAD);
VAR_0->regs[DBDMA_STATUS] &= cpu_to_be32(~ACTIVE);
qemu_irq_raise(VAR_0->irq);
}
| [
"static void FUNC_0(DBDMA_channel *VAR_0)\n{",
"DBDMA_DPRINTF(\"FUNC_0\\n\");",
"VAR_0->regs[DBDMA_STATUS] |= cpu_to_be32(DEAD);",
"VAR_0->regs[DBDMA_STATUS] &= cpu_to_be32(~ACTIVE);",
"qemu_irq_raise(VAR_0->irq);",
"}"
] | [
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
],
[
15
],
[
17
]
] |
4,547 | static void scsi_do_read(SCSIDiskReq *r, int ret)
{
SCSIDiskState *s = DO_UPCAST(SCSIDiskState, qdev, r->req.dev);
SCSIDiskClass *sdc = (SCSIDiskClass *) object_get_class(OBJECT(s));
assert (r->req.aiocb == NULL);
if (r->req.io_canceled) {
scsi_req_cancel_complete(&r->req);
go... | false | qemu | 5b956f415a356449a4171d5e0c7d9a25bbc84b5a | static void scsi_do_read(SCSIDiskReq *r, int ret)
{
SCSIDiskState *s = DO_UPCAST(SCSIDiskState, qdev, r->req.dev);
SCSIDiskClass *sdc = (SCSIDiskClass *) object_get_class(OBJECT(s));
assert (r->req.aiocb == NULL);
if (r->req.io_canceled) {
scsi_req_cancel_complete(&r->req);
go... | {
"code": [],
"line_no": []
} | static void FUNC_0(SCSIDiskReq *VAR_0, int VAR_1)
{
SCSIDiskState *s = DO_UPCAST(SCSIDiskState, qdev, VAR_0->req.dev);
SCSIDiskClass *sdc = (SCSIDiskClass *) object_get_class(OBJECT(s));
assert (VAR_0->req.aiocb == NULL);
if (VAR_0->req.io_canceled) {
scsi_req_cancel_complete(&VAR_0->r... | [
"static void FUNC_0(SCSIDiskReq *VAR_0, int VAR_1)\n{",
"SCSIDiskState *s = DO_UPCAST(SCSIDiskState, qdev, VAR_0->req.dev);",
"SCSIDiskClass *sdc = (SCSIDiskClass *) object_get_class(OBJECT(s));",
"assert (VAR_0->req.aiocb == NULL);",
"if (VAR_0->req.io_canceled) {",
"scsi_req_cancel_complete(&VAR_0->req)... | [
0,
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
],
[
15
],
[
17
],
[
19
],
[
21
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
39
],
[
43
],
[
45
],
[
47
],
[
49,
51,
53,
55
],
... |
4,548 | static inline void _cpu_ppc_store_hdecr(PowerPCCPU *cpu, uint32_t hdecr,
uint32_t value, int is_excp)
{
ppc_tb_t *tb_env = cpu->env.tb_env;
if (tb_env->hdecr_timer != NULL) {
__cpu_ppc_store_decr(cpu, &tb_env->hdecr_next, tb_env->hdecr_timer,
... | false | qemu | e81a982aa5398269a2cc344091ffa4930bdd242f | static inline void _cpu_ppc_store_hdecr(PowerPCCPU *cpu, uint32_t hdecr,
uint32_t value, int is_excp)
{
ppc_tb_t *tb_env = cpu->env.tb_env;
if (tb_env->hdecr_timer != NULL) {
__cpu_ppc_store_decr(cpu, &tb_env->hdecr_next, tb_env->hdecr_timer,
... | {
"code": [],
"line_no": []
} | static inline void FUNC_0(PowerPCCPU *VAR_0, uint32_t VAR_1,
uint32_t VAR_2, int VAR_3)
{
ppc_tb_t *tb_env = VAR_0->env.tb_env;
if (tb_env->hdecr_timer != NULL) {
__cpu_ppc_store_decr(VAR_0, &tb_env->hdecr_next, tb_env->hdecr_timer,
... | [
"static inline void FUNC_0(PowerPCCPU *VAR_0, uint32_t VAR_1,\nuint32_t VAR_2, int VAR_3)\n{",
"ppc_tb_t *tb_env = VAR_0->env.tb_env;",
"if (tb_env->hdecr_timer != NULL) {",
"__cpu_ppc_store_decr(VAR_0, &tb_env->hdecr_next, tb_env->hdecr_timer,\n&cpu_ppc_hdecr_excp, VAR_1, VAR_2, VAR_3);",
"}",
"}"
] | [
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
11
],
[
13,
15
],
[
17
],
[
19
]
] |
4,549 | static void readline_printf_func(void *opaque, const char *fmt, ...)
{
va_list ap;
va_start(ap, fmt);
vprintf(fmt, ap);
va_end(ap);
}
| false | qemu | d5d1507b347b7cd6c3b82459b96f1889b29939ef | static void readline_printf_func(void *opaque, const char *fmt, ...)
{
va_list ap;
va_start(ap, fmt);
vprintf(fmt, ap);
va_end(ap);
}
| {
"code": [],
"line_no": []
} | static void FUNC_0(void *VAR_0, const char *VAR_1, ...)
{
va_list ap;
va_start(ap, VAR_1);
vprintf(VAR_1, ap);
va_end(ap);
}
| [
"static void FUNC_0(void *VAR_0, const char *VAR_1, ...)\n{",
"va_list ap;",
"va_start(ap, VAR_1);",
"vprintf(VAR_1, ap);",
"va_end(ap);",
"}"
] | [
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
]
] |
4,550 | static ssize_t virtio_net_receive(VLANClientState *vc, const uint8_t *buf, size_t size)
{
VirtIONet *n = vc->opaque;
struct virtio_net_hdr_mrg_rxbuf *mhdr = NULL;
size_t hdr_len, offset, i;
if (!do_virtio_net_can_receive(n, size))
return 0;
if (!receive_filter(n, buf, size))
... | false | qemu | cdd5cc12ba8cf0c068da319370bdd3ba45eaf7ac | static ssize_t virtio_net_receive(VLANClientState *vc, const uint8_t *buf, size_t size)
{
VirtIONet *n = vc->opaque;
struct virtio_net_hdr_mrg_rxbuf *mhdr = NULL;
size_t hdr_len, offset, i;
if (!do_virtio_net_can_receive(n, size))
return 0;
if (!receive_filter(n, buf, size))
... | {
"code": [],
"line_no": []
} | static ssize_t FUNC_0(VLANClientState *vc, const uint8_t *buf, size_t size)
{
VirtIONet *n = vc->opaque;
struct virtio_net_hdr_mrg_rxbuf *VAR_0 = NULL;
size_t hdr_len, offset, i;
if (!do_virtio_net_can_receive(n, size))
return 0;
if (!receive_filter(n, buf, size))
return ... | [
"static ssize_t FUNC_0(VLANClientState *vc, const uint8_t *buf, size_t size)\n{",
"VirtIONet *n = vc->opaque;",
"struct virtio_net_hdr_mrg_rxbuf *VAR_0 = NULL;",
"size_t hdr_len, offset, i;",
"if (!do_virtio_net_can_receive(n, size))\nreturn 0;",
"if (!receive_filter(n, buf, size))\nreturn size;",
"hdr_... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
27,
29
],
[
33
],
[
37
],
[
39
],
[
41
],
[
43
],
[
47
],
[
51,
53
],
[
55,
57
],
[
59
],
[
61
],
[... |
4,552 | static CharDriverState *text_console_init(ChardevVC *vc, Error **errp)
{
CharDriverState *chr;
QemuConsole *s;
unsigned width = 0;
unsigned height = 0;
chr = qemu_chr_alloc();
if (vc->has_width) {
width = vc->width;
} else if (vc->has_cols) {
width = vc->cols * ... | false | qemu | d0d7708ba29cbcc343364a46bff981e0ff88366f | static CharDriverState *text_console_init(ChardevVC *vc, Error **errp)
{
CharDriverState *chr;
QemuConsole *s;
unsigned width = 0;
unsigned height = 0;
chr = qemu_chr_alloc();
if (vc->has_width) {
width = vc->width;
} else if (vc->has_cols) {
width = vc->cols * ... | {
"code": [],
"line_no": []
} | static CharDriverState *FUNC_0(ChardevVC *vc, Error **errp)
{
CharDriverState *chr;
QemuConsole *s;
unsigned VAR_0 = 0;
unsigned VAR_1 = 0;
chr = qemu_chr_alloc();
if (vc->has_width) {
VAR_0 = vc->VAR_0;
} else if (vc->has_cols) {
VAR_0 = vc->cols * FONT_WIDTH;
... | [
"static CharDriverState *FUNC_0(ChardevVC *vc, Error **errp)\n{",
"CharDriverState *chr;",
"QemuConsole *s;",
"unsigned VAR_0 = 0;",
"unsigned VAR_1 = 0;",
"chr = qemu_chr_alloc();",
"if (vc->has_width) {",
"VAR_0 = vc->VAR_0;",
"} else if (vc->has_cols) {",
"VAR_0 = vc->cols * FONT_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
],
[
11
],
[
15
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
43
],
[
45
],
[
47
],
[
49
... |
4,553 | static int vhdx_log_flush(BlockDriverState *bs, BDRVVHDXState *s,
VHDXLogSequence *logs)
{
int ret = 0;
int i;
uint32_t cnt, sectors_read;
uint64_t new_file_size;
void *data = NULL;
int64_t file_length;
VHDXLogDescEntries *desc_entries = NULL;
VHDXLogE... | false | qemu | 95d729835f3ceeed977eaf326a7ebb92788dee6d | static int vhdx_log_flush(BlockDriverState *bs, BDRVVHDXState *s,
VHDXLogSequence *logs)
{
int ret = 0;
int i;
uint32_t cnt, sectors_read;
uint64_t new_file_size;
void *data = NULL;
int64_t file_length;
VHDXLogDescEntries *desc_entries = NULL;
VHDXLogE... | {
"code": [],
"line_no": []
} | static int FUNC_0(BlockDriverState *VAR_0, BDRVVHDXState *VAR_1,
VHDXLogSequence *VAR_2)
{
int VAR_3 = 0;
int VAR_4;
uint32_t cnt, sectors_read;
uint64_t new_file_size;
void *VAR_5 = NULL;
int64_t file_length;
VHDXLogDescEntries *desc_entries = NULL;
V... | [
"static int FUNC_0(BlockDriverState *VAR_0, BDRVVHDXState *VAR_1,\nVHDXLogSequence *VAR_2)\n{",
"int VAR_3 = 0;",
"int VAR_4;",
"uint32_t cnt, sectors_read;",
"uint64_t new_file_size;",
"void *VAR_5 = NULL;",
"int64_t file_length;",
"VHDXLogDescEntries *desc_entries = NULL;",
"VHDXLogEntryHeader hdr... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
29
],
[
33
],
[
35
],
[
37
],
[
39
],
[
47
],
[
49
],
[
51
],
[
53
],
[... |
4,554 | int ff_intel_h263_decode_picture_header(MpegEncContext *s)
{
int format;
/* picture header */
if (get_bits_long(&s->gb, 22) != 0x20) {
av_log(s->avctx, AV_LOG_ERROR, "Bad picture start code\n");
return -1;
}
s->picture_number = get_bits(&s->gb, 8); /* picture timestamp */
... | false | FFmpeg | cc229d4e83889d1298f1a0863b55feec6c5c339a | int ff_intel_h263_decode_picture_header(MpegEncContext *s)
{
int format;
if (get_bits_long(&s->gb, 22) != 0x20) {
av_log(s->avctx, AV_LOG_ERROR, "Bad picture start code\n");
return -1;
}
s->picture_number = get_bits(&s->gb, 8);
if (get_bits1(&s->gb) != 1) {
... | {
"code": [],
"line_no": []
} | int FUNC_0(MpegEncContext *VAR_0)
{
int VAR_1;
if (get_bits_long(&VAR_0->gb, 22) != 0x20) {
av_log(VAR_0->avctx, AV_LOG_ERROR, "Bad picture start code\n");
return -1;
}
VAR_0->picture_number = get_bits(&VAR_0->gb, 8);
if (get_bits1(&VAR_0->gb) != 1) {
av_l... | [
"int FUNC_0(MpegEncContext *VAR_0)\n{",
"int VAR_1;",
"if (get_bits_long(&VAR_0->gb, 22) != 0x20) {",
"av_log(VAR_0->avctx, AV_LOG_ERROR, \"Bad picture start code\\n\");",
"return -1;",
"}",
"VAR_0->picture_number = get_bits(&VAR_0->gb, 8);",
"if (get_bits1(&VAR_0->gb) != 1) {",
"av_log(VAR_0->avctx... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
47
],
[
4... |
4,558 | static ssize_t nbd_co_send_reply(NBDRequest *req, struct nbd_reply *reply,
int len)
{
NBDClient *client = req->client;
int csock = client->sock;
ssize_t rc, ret;
qemu_co_mutex_lock(&client->send_lock);
qemu_set_fd_handler2(csock, nbd_can_read, nbd_read,
... | false | qemu | 958c717df97ea9ca47a2253b8371130fe5f22980 | static ssize_t nbd_co_send_reply(NBDRequest *req, struct nbd_reply *reply,
int len)
{
NBDClient *client = req->client;
int csock = client->sock;
ssize_t rc, ret;
qemu_co_mutex_lock(&client->send_lock);
qemu_set_fd_handler2(csock, nbd_can_read, nbd_read,
... | {
"code": [],
"line_no": []
} | static ssize_t FUNC_0(NBDRequest *req, struct nbd_reply *reply,
int len)
{
NBDClient *client = req->client;
int VAR_0 = client->sock;
ssize_t rc, ret;
qemu_co_mutex_lock(&client->send_lock);
qemu_set_fd_handler2(VAR_0, nbd_can_read, nbd_read,
... | [
"static ssize_t FUNC_0(NBDRequest *req, struct nbd_reply *reply,\nint len)\n{",
"NBDClient *client = req->client;",
"int VAR_0 = client->sock;",
"ssize_t rc, ret;",
"qemu_co_mutex_lock(&client->send_lock);",
"qemu_set_fd_handler2(VAR_0, nbd_can_read, nbd_read,\nnbd_restart_write, client);",
"client->sen... | [
0,
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
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
... |
4,559 | int64_t qemu_file_set_rate_limit(QEMUFile *f, int64_t new_rate)
{
/* any failed or completed migration keeps its state to allow probing of
* migration data, but has no associated file anymore */
if (f && f->ops->set_rate_limit)
return f->ops->set_rate_limit(f->opaque, new_rate);
return ... | false | qemu | 1964a397063967acc5ce71a2a24ed26e74824ee1 | int64_t qemu_file_set_rate_limit(QEMUFile *f, int64_t new_rate)
{
if (f && f->ops->set_rate_limit)
return f->ops->set_rate_limit(f->opaque, new_rate);
return 0;
}
| {
"code": [],
"line_no": []
} | int64_t FUNC_0(QEMUFile *f, int64_t new_rate)
{
if (f && f->ops->set_rate_limit)
return f->ops->set_rate_limit(f->opaque, new_rate);
return 0;
}
| [
"int64_t FUNC_0(QEMUFile *f, int64_t new_rate)\n{",
"if (f && f->ops->set_rate_limit)\nreturn f->ops->set_rate_limit(f->opaque, new_rate);",
"return 0;",
"}"
] | [
0,
0,
0,
0
] | [
[
1,
3
],
[
9,
11
],
[
15
],
[
17
]
] |
4,560 | static uint64_t lance_mem_read(void *opaque, target_phys_addr_t addr,
unsigned size)
{
SysBusPCNetState *d = opaque;
uint32_t val;
val = pcnet_ioport_readw(&d->state, addr);
trace_lance_mem_readw(addr, val & 0xffff);
return val & 0xffff;
}
| false | qemu | a8170e5e97ad17ca169c64ba87ae2f53850dab4c | static uint64_t lance_mem_read(void *opaque, target_phys_addr_t addr,
unsigned size)
{
SysBusPCNetState *d = opaque;
uint32_t val;
val = pcnet_ioport_readw(&d->state, addr);
trace_lance_mem_readw(addr, val & 0xffff);
return val & 0xffff;
}
| {
"code": [],
"line_no": []
} | static uint64_t FUNC_0(void *opaque, target_phys_addr_t addr,
unsigned size)
{
SysBusPCNetState *d = opaque;
uint32_t val;
val = pcnet_ioport_readw(&d->state, addr);
trace_lance_mem_readw(addr, val & 0xffff);
return val & 0xffff;
}
| [
"static uint64_t FUNC_0(void *opaque, target_phys_addr_t addr,\nunsigned size)\n{",
"SysBusPCNetState *d = opaque;",
"uint32_t val;",
"val = pcnet_ioport_readw(&d->state, addr);",
"trace_lance_mem_readw(addr, val & 0xffff);",
"return val & 0xffff;",
"}"
] | [
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
17
],
[
19
]
] |
4,561 | int tcp_socket_outgoing_opts(QemuOpts *opts)
{
Error *local_err = NULL;
int fd = inet_connect_opts(opts, &local_err, NULL, NULL);
if (local_err != NULL) {
qerror_report_err(local_err);
error_free(local_err);
}
return fd;
}
| false | qemu | 77e8b9ca64e85d3d309f322410964b7852ec091e | int tcp_socket_outgoing_opts(QemuOpts *opts)
{
Error *local_err = NULL;
int fd = inet_connect_opts(opts, &local_err, NULL, NULL);
if (local_err != NULL) {
qerror_report_err(local_err);
error_free(local_err);
}
return fd;
}
| {
"code": [],
"line_no": []
} | int FUNC_0(QemuOpts *VAR_0)
{
Error *local_err = NULL;
int VAR_1 = inet_connect_opts(VAR_0, &local_err, NULL, NULL);
if (local_err != NULL) {
qerror_report_err(local_err);
error_free(local_err);
}
return VAR_1;
}
| [
"int FUNC_0(QemuOpts *VAR_0)\n{",
"Error *local_err = NULL;",
"int VAR_1 = inet_connect_opts(VAR_0, &local_err, NULL, NULL);",
"if (local_err != NULL) {",
"qerror_report_err(local_err);",
"error_free(local_err);",
"}",
"return VAR_1;",
"}"
] | [
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
19
],
[
21
]
] |
4,562 | static inline int onenand_prog_spare(OneNANDState *s, int sec, int secn,
void *src)
{
int result = 0;
if (secn > 0) {
const uint8_t *sp = (const uint8_t *)src;
uint8_t *dp = 0, *dpp = 0;
if (s->bdrv_cur) {
dp = g_malloc(512);
if (!dp || bd... | false | qemu | 4be746345f13e99e468c60acbd3a355e8183e3ce | static inline int onenand_prog_spare(OneNANDState *s, int sec, int secn,
void *src)
{
int result = 0;
if (secn > 0) {
const uint8_t *sp = (const uint8_t *)src;
uint8_t *dp = 0, *dpp = 0;
if (s->bdrv_cur) {
dp = g_malloc(512);
if (!dp || bd... | {
"code": [],
"line_no": []
} | static inline int FUNC_0(OneNANDState *VAR_0, int VAR_1, int VAR_2,
void *VAR_3)
{
int VAR_4 = 0;
if (VAR_2 > 0) {
const uint8_t *VAR_5 = (const uint8_t *)VAR_3;
uint8_t *dp = 0, *dpp = 0;
if (VAR_0->bdrv_cur) {
dp = g_malloc(512);
if (!dp... | [
"static inline int FUNC_0(OneNANDState *VAR_0, int VAR_1, int VAR_2,\nvoid *VAR_3)\n{",
"int VAR_4 = 0;",
"if (VAR_2 > 0) {",
"const uint8_t *VAR_5 = (const uint8_t *)VAR_3;",
"uint8_t *dp = 0, *dpp = 0;",
"if (VAR_0->bdrv_cur) {",
"dp = g_malloc(512);",
"if (!dp || bdrv_read(VAR_0->bdrv_cur,\nVAR_0->... | [
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[... |
4,564 | static void setup_rt_frame(int sig, struct target_sigaction *ka,
target_siginfo_t *info,
target_sigset_t *set, CPUM68KState *env)
{
struct target_rt_sigframe *frame;
abi_ulong frame_addr;
abi_ulong retcode_addr;
abi_ulong info_addr;
abi_u... | false | qemu | b0fd8d18683f0d77a8e6b482771ebea82234d727 | static void setup_rt_frame(int sig, struct target_sigaction *ka,
target_siginfo_t *info,
target_sigset_t *set, CPUM68KState *env)
{
struct target_rt_sigframe *frame;
abi_ulong frame_addr;
abi_ulong retcode_addr;
abi_ulong info_addr;
abi_u... | {
"code": [],
"line_no": []
} | static void FUNC_0(int VAR_0, struct target_sigaction *VAR_1,
target_siginfo_t *VAR_2,
target_sigset_t *VAR_3, CPUM68KState *VAR_4)
{
struct target_rt_sigframe *VAR_5;
abi_ulong frame_addr;
abi_ulong retcode_addr;
abi_ulong info_addr;
abi... | [
"static void FUNC_0(int VAR_0, struct target_sigaction *VAR_1,\ntarget_siginfo_t *VAR_2,\ntarget_sigset_t *VAR_3, CPUM68KState *VAR_4)\n{",
"struct target_rt_sigframe *VAR_5;",
"abi_ulong frame_addr;",
"abi_ulong retcode_addr;",
"abi_ulong info_addr;",
"abi_ulong uc_addr;",
"int VAR_6 = 0;",
"int 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,
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
],
[
33
],
[
37
],
[
39
],
[
43
],
[
45
],
[
49
],
[
57
],
[
59
],
[... |
4,565 | static int mov_read_stsz(MOVContext *c, AVIOContext *pb, MOVAtom atom)
{
AVStream *st;
MOVStreamContext *sc;
unsigned int i, entries, sample_size, field_size, num_bytes;
GetBitContext gb;
unsigned char* buf;
if (c->fc->nb_streams < 1)
return 0;
st = c->fc->streams[c->fc->n... | false | FFmpeg | 9888ffb1ce5e0a17f711b01933d504c72ea29d3b | static int mov_read_stsz(MOVContext *c, AVIOContext *pb, MOVAtom atom)
{
AVStream *st;
MOVStreamContext *sc;
unsigned int i, entries, sample_size, field_size, num_bytes;
GetBitContext gb;
unsigned char* buf;
if (c->fc->nb_streams < 1)
return 0;
st = c->fc->streams[c->fc->n... | {
"code": [],
"line_no": []
} | static int FUNC_0(MOVContext *VAR_0, AVIOContext *VAR_1, MOVAtom VAR_2)
{
AVStream *st;
MOVStreamContext *sc;
unsigned int VAR_3, VAR_4, VAR_5, VAR_6, VAR_7;
GetBitContext gb;
unsigned char* VAR_8;
if (VAR_0->fc->nb_streams < 1)
return 0;
st = VAR_0->fc->streams[VAR_0->fc-... | [
"static int FUNC_0(MOVContext *VAR_0, AVIOContext *VAR_1, MOVAtom VAR_2)\n{",
"AVStream *st;",
"MOVStreamContext *sc;",
"unsigned int VAR_3, VAR_4, VAR_5, VAR_6, VAR_7;",
"GetBitContext gb;",
"unsigned char* VAR_8;",
"if (VAR_0->fc->nb_streams < 1)\nreturn 0;",
"st = VAR_0->fc->streams[VAR_0->fc->nb_s... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
27
],
[
29
],
[
33
],
[
35
],
[
37,
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49
... |
4,566 | static QEMUFile *qemu_fopen_bdrv(BlockDriverState *bs, int64_t offset, int is_writable)
{
QEMUFile *f;
f = qemu_mallocz(sizeof(QEMUFile));
if (!f)
return NULL;
f->is_file = 0;
f->bs = bs;
f->is_writable = is_writable;
f->base_offset = offset;
return f;
}
| false | qemu | 5dafc53f1fb091d242f2179ffcb43bb28af36d1e | static QEMUFile *qemu_fopen_bdrv(BlockDriverState *bs, int64_t offset, int is_writable)
{
QEMUFile *f;
f = qemu_mallocz(sizeof(QEMUFile));
if (!f)
return NULL;
f->is_file = 0;
f->bs = bs;
f->is_writable = is_writable;
f->base_offset = offset;
return f;
}
| {
"code": [],
"line_no": []
} | static QEMUFile *FUNC_0(BlockDriverState *bs, int64_t offset, int is_writable)
{
QEMUFile *f;
f = qemu_mallocz(sizeof(QEMUFile));
if (!f)
return NULL;
f->is_file = 0;
f->bs = bs;
f->is_writable = is_writable;
f->base_offset = offset;
return f;
}
| [
"static QEMUFile *FUNC_0(BlockDriverState *bs, int64_t offset, int is_writable)\n{",
"QEMUFile *f;",
"f = qemu_mallocz(sizeof(QEMUFile));",
"if (!f)\nreturn NULL;",
"f->is_file = 0;",
"f->bs = bs;",
"f->is_writable = is_writable;",
"f->base_offset = offset;",
"return f;",
"}"
] | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11,
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
]
] |
4,567 | static void virtio_setup(void)
{
struct irb irb;
int i;
int r;
bool found = false;
blk_schid.one = 1;
for (i = 0; i < 0x10000; i++) {
blk_schid.sch_no = i;
r = tsch(blk_schid, &irb);
if (r != 3) {
if (virtio_is_blk(blk_schid)) {
... | false | qemu | 22d67ab55aad82383a0e5628b902a1a0556b2fc9 | static void virtio_setup(void)
{
struct irb irb;
int i;
int r;
bool found = false;
blk_schid.one = 1;
for (i = 0; i < 0x10000; i++) {
blk_schid.sch_no = i;
r = tsch(blk_schid, &irb);
if (r != 3) {
if (virtio_is_blk(blk_schid)) {
... | {
"code": [],
"line_no": []
} | static void FUNC_0(void)
{
struct VAR_0 VAR_0;
int VAR_1;
int VAR_2;
bool found = false;
blk_schid.one = 1;
for (VAR_1 = 0; VAR_1 < 0x10000; VAR_1++) {
blk_schid.sch_no = VAR_1;
VAR_2 = tsch(blk_schid, &VAR_0);
if (VAR_2 != 3) {
if (virtio_is_bl... | [
"static void FUNC_0(void)\n{",
"struct VAR_0 VAR_0;",
"int VAR_1;",
"int VAR_2;",
"bool found = false;",
"blk_schid.one = 1;",
"for (VAR_1 = 0; VAR_1 < 0x10000; VAR_1++) {",
"blk_schid.sch_no = VAR_1;",
"VAR_2 = tsch(blk_schid, &VAR_0);",
"if (VAR_2 != 3) {",
"if (virtio_is_blk(blk_schid)) {",
... | [
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
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
41
],
[
43
],
[
45
],
[
49
... |
4,568 | int if_encap(Slirp *slirp, struct mbuf *ifm)
{
uint8_t buf[1600];
struct ethhdr *eh = (struct ethhdr *)buf;
uint8_t ethaddr[ETH_ALEN];
const struct ip *iph = (const struct ip *)ifm->m_data;
int ret;
if (ifm->m_len + ETH_HLEN > sizeof(buf)) {
return 1;
}
switch (iph-... | false | qemu | 0d6ff71ae3c7ac3a446d295ef71884a05093b37c | int if_encap(Slirp *slirp, struct mbuf *ifm)
{
uint8_t buf[1600];
struct ethhdr *eh = (struct ethhdr *)buf;
uint8_t ethaddr[ETH_ALEN];
const struct ip *iph = (const struct ip *)ifm->m_data;
int ret;
if (ifm->m_len + ETH_HLEN > sizeof(buf)) {
return 1;
}
switch (iph-... | {
"code": [],
"line_no": []
} | int FUNC_0(Slirp *VAR_0, struct mbuf *VAR_1)
{
uint8_t buf[1600];
struct ethhdr *VAR_2 = (struct ethhdr *)buf;
uint8_t ethaddr[ETH_ALEN];
const struct ip *VAR_3 = (const struct ip *)VAR_1->m_data;
int VAR_4;
if (VAR_1->m_len + ETH_HLEN > sizeof(buf)) {
return 1;
}
s... | [
"int FUNC_0(Slirp *VAR_0, struct mbuf *VAR_1)\n{",
"uint8_t buf[1600];",
"struct ethhdr *VAR_2 = (struct ethhdr *)buf;",
"uint8_t ethaddr[ETH_ALEN];",
"const struct ip *VAR_3 = (const struct ip *)VAR_1->m_data;",
"int VAR_4;",
"if (VAR_1->m_len + ETH_HLEN > sizeof(buf)) {",
"return 1;",
"}",
"swit... | [
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
],
[
25
],
[
27,
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
41,
47
],
[
49
],
[
53
],
[
55,... |
4,572 | static void fill_thread_info(struct elf_note_info *info, const CPUState *env)
{
TaskState *ts = (TaskState *)env->opaque;
struct elf_thread_status *ets;
ets = qemu_mallocz(sizeof (*ets));
ets->num_notes = 1; /* only prstatus is dumped */
fill_prstatus(&ets->prstatus, ts, 0);
elf_core_co... | false | qemu | 72cf2d4f0e181d0d3a3122e04129c58a95da713e | static void fill_thread_info(struct elf_note_info *info, const CPUState *env)
{
TaskState *ts = (TaskState *)env->opaque;
struct elf_thread_status *ets;
ets = qemu_mallocz(sizeof (*ets));
ets->num_notes = 1;
fill_prstatus(&ets->prstatus, ts, 0);
elf_core_copy_regs(&ets->prstatus.pr_reg... | {
"code": [],
"line_no": []
} | static void FUNC_0(struct elf_note_info *VAR_0, const CPUState *VAR_1)
{
TaskState *ts = (TaskState *)VAR_1->opaque;
struct elf_thread_status *VAR_2;
VAR_2 = qemu_mallocz(sizeof (*VAR_2));
VAR_2->num_notes = 1;
fill_prstatus(&VAR_2->prstatus, ts, 0);
elf_core_copy_regs(&VAR_2->prstatus... | [
"static void FUNC_0(struct elf_note_info *VAR_0, const CPUState *VAR_1)\n{",
"TaskState *ts = (TaskState *)VAR_1->opaque;",
"struct elf_thread_status *VAR_2;",
"VAR_2 = qemu_mallocz(sizeof (*VAR_2));",
"VAR_2->num_notes = 1;",
"fill_prstatus(&VAR_2->prstatus, ts, 0);",
"elf_core_copy_regs(&VAR_2->prstat... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19,
21
],
[
25
],
[
29
],
[
31
]
] |
4,573 | static void omap_screen_dump(void *opaque, const char *filename, bool cswitch,
Error **errp)
{
struct omap_lcd_panel_s *omap_lcd = opaque;
DisplaySurface *surface = qemu_console_surface(omap_lcd->con);
omap_update_display(opaque);
if (omap_lcd && surface_data(surface... | false | qemu | 2c62f08ddbf3fa80dc7202eb9a2ea60ae44e2cc5 | static void omap_screen_dump(void *opaque, const char *filename, bool cswitch,
Error **errp)
{
struct omap_lcd_panel_s *omap_lcd = opaque;
DisplaySurface *surface = qemu_console_surface(omap_lcd->con);
omap_update_display(opaque);
if (omap_lcd && surface_data(surface... | {
"code": [],
"line_no": []
} | static void FUNC_0(void *VAR_0, const char *VAR_1, bool VAR_2,
Error **VAR_3)
{
struct omap_lcd_panel_s *VAR_4 = VAR_0;
DisplaySurface *surface = qemu_console_surface(VAR_4->con);
omap_update_display(VAR_0);
if (VAR_4 && surface_data(surface))
omap_ppm_save(... | [
"static void FUNC_0(void *VAR_0, const char *VAR_1, bool VAR_2,\nError **VAR_3)\n{",
"struct omap_lcd_panel_s *VAR_4 = VAR_0;",
"DisplaySurface *surface = qemu_console_surface(VAR_4->con);",
"omap_update_display(VAR_0);",
"if (VAR_4 && surface_data(surface))\nomap_ppm_save(VAR_1, surface_data(surface),\nVAR... | [
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
13
],
[
15,
17,
19,
21
],
[
23
]
] |
4,574 | static void con_disconnect(struct XenDevice *xendev)
{
struct XenConsole *con = container_of(xendev, struct XenConsole, xendev);
if (!xendev->dev) {
return;
}
if (con->chr) {
qemu_chr_add_handlers(con->chr, NULL, NULL, NULL, NULL);
qemu_chr_fe_release(con->chr);
}
... | false | qemu | 549e9bcabc2f5b37b0be8c24257e0b527bffb49a | static void con_disconnect(struct XenDevice *xendev)
{
struct XenConsole *con = container_of(xendev, struct XenConsole, xendev);
if (!xendev->dev) {
return;
}
if (con->chr) {
qemu_chr_add_handlers(con->chr, NULL, NULL, NULL, NULL);
qemu_chr_fe_release(con->chr);
}
... | {
"code": [],
"line_no": []
} | static void FUNC_0(struct XenDevice *VAR_0)
{
struct XenConsole *VAR_1 = container_of(VAR_0, struct XenConsole, VAR_0);
if (!VAR_0->dev) {
return;
}
if (VAR_1->chr) {
qemu_chr_add_handlers(VAR_1->chr, NULL, NULL, NULL, NULL);
qemu_chr_fe_release(VAR_1->chr);
}
... | [
"static void FUNC_0(struct XenDevice *VAR_0)\n{",
"struct XenConsole *VAR_1 = container_of(VAR_0, struct XenConsole, VAR_0);",
"if (!VAR_0->dev) {",
"return;",
"}",
"if (VAR_1->chr) {",
"qemu_chr_add_handlers(VAR_1->chr, NULL, NULL, NULL, NULL);",
"qemu_chr_fe_release(VAR_1->chr);",
"}",
"xen_be_u... | [
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
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
]
] |
4,576 | static int configure_input_video_filter(FilterGraph *fg, InputFilter *ifilter,
AVFilterInOut *in)
{
AVFilterContext *last_filter;
const AVFilter *buffer_filt = avfilter_get_by_name("buffer");
InputStream *ist = ifilter->ist;
InputFile *f = input_files[is... | false | FFmpeg | 488a0fa68973d48e264d54f1722f7afb18afbea7 | static int configure_input_video_filter(FilterGraph *fg, InputFilter *ifilter,
AVFilterInOut *in)
{
AVFilterContext *last_filter;
const AVFilter *buffer_filt = avfilter_get_by_name("buffer");
InputStream *ist = ifilter->ist;
InputFile *f = input_files[is... | {
"code": [],
"line_no": []
} | static int FUNC_0(FilterGraph *VAR_0, InputFilter *VAR_1,
AVFilterInOut *VAR_2)
{
AVFilterContext *last_filter;
const AVFilter *VAR_3 = avfilter_get_by_name("buffer");
InputStream *ist = VAR_1->ist;
InputFile *f = input_files[ist->file_index];
AVRat... | [
"static int FUNC_0(FilterGraph *VAR_0, InputFilter *VAR_1,\nAVFilterInOut *VAR_2)\n{",
"AVFilterContext *last_filter;",
"const AVFilter *VAR_3 = avfilter_get_by_name(\"buffer\");",
"InputStream *ist = VAR_1->ist;",
"InputFile *f = input_files[ist->file_index];",
"AVRational tb = ist->framerate.num ? a... | [
0,
0,
0,
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,
35,
37
],
[
39,
41
],
[
45,
47,
49
],
[
51
],
[
55
],
[... |
4,577 | void ff_put_h264_qpel16_mc33_msa(uint8_t *dst, const uint8_t *src,
ptrdiff_t stride)
{
avc_luma_hv_qrt_16w_msa(src + stride - 2,
src - (stride * 2) +
sizeof(uint8_t), stride, dst, stride, 16);
}
| false | FFmpeg | 2aab7c2dfaca4386c38e5d565cd2bf73096bcc86 | void ff_put_h264_qpel16_mc33_msa(uint8_t *dst, const uint8_t *src,
ptrdiff_t stride)
{
avc_luma_hv_qrt_16w_msa(src + stride - 2,
src - (stride * 2) +
sizeof(uint8_t), stride, dst, stride, 16);
}
| {
"code": [],
"line_no": []
} | void FUNC_0(uint8_t *VAR_0, const uint8_t *VAR_1,
ptrdiff_t VAR_2)
{
avc_luma_hv_qrt_16w_msa(VAR_1 + VAR_2 - 2,
VAR_1 - (VAR_2 * 2) +
sizeof(uint8_t), VAR_2, VAR_0, VAR_2, 16);
}
| [
"void FUNC_0(uint8_t *VAR_0, const uint8_t *VAR_1,\nptrdiff_t VAR_2)\n{",
"avc_luma_hv_qrt_16w_msa(VAR_1 + VAR_2 - 2,\nVAR_1 - (VAR_2 * 2) +\nsizeof(uint8_t), VAR_2, VAR_0, VAR_2, 16);",
"}"
] | [
0,
0,
0
] | [
[
1,
3,
5
],
[
7,
9,
11
],
[
13
]
] |
4,579 | int qcow2_backing_read1(BlockDriverState *bs, QEMUIOVector *qiov,
int64_t offset, int bytes)
{
uint64_t bs_size = bs->total_sectors * BDRV_SECTOR_SIZE;
int n1;
if ((offset + bytes) <= bs_size) {
return bytes;
}
if (offset >= bs_size) {
n1 = 0;
... | true | qemu | 546a7dc40e8b8b6440a052e2b5cdfe9aadcaccf6 | int qcow2_backing_read1(BlockDriverState *bs, QEMUIOVector *qiov,
int64_t offset, int bytes)
{
uint64_t bs_size = bs->total_sectors * BDRV_SECTOR_SIZE;
int n1;
if ((offset + bytes) <= bs_size) {
return bytes;
}
if (offset >= bs_size) {
n1 = 0;
... | {
"code": [
"int qcow2_backing_read1(BlockDriverState *bs, QEMUIOVector *qiov,",
" int64_t offset, int bytes)",
" uint64_t bs_size = bs->total_sectors * BDRV_SECTOR_SIZE;",
" int n1;",
" if ((offset + bytes) <= bs_size) {",
" return bytes;",
" if (... | int FUNC_0(BlockDriverState *VAR_0, QEMUIOVector *VAR_1,
int64_t VAR_2, int VAR_3)
{
uint64_t bs_size = VAR_0->total_sectors * BDRV_SECTOR_SIZE;
int VAR_4;
if ((VAR_2 + VAR_3) <= bs_size) {
return VAR_3;
}
if (VAR_2 >= bs_size) {
VAR_4 = 0;
}... | [
"int FUNC_0(BlockDriverState *VAR_0, QEMUIOVector *VAR_1,\nint64_t VAR_2, int VAR_3)\n{",
"uint64_t bs_size = VAR_0->total_sectors * BDRV_SECTOR_SIZE;",
"int VAR_4;",
"if ((VAR_2 + VAR_3) <= bs_size) {",
"return VAR_3;",
"}",
"if (VAR_2 >= bs_size) {",
"VAR_4 = 0;",
"} else {",
"VAR_4 = bs_size - ... | [
1,
1,
1,
1,
1,
0,
1,
1,
0,
1,
0,
1,
1,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
17
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
33
],
[
37
],
[
39
]
] |
4,581 | static void property_get_bool(Object *obj, Visitor *v, void *opaque,
const char *name, Error **errp)
{
BoolProperty *prop = opaque;
bool value;
value = prop->get(obj, errp);
visit_type_bool(v, &value, name, errp);
}
| true | qemu | 4715d42efe8632b0f9d2594a80e917de45e4ef88 | static void property_get_bool(Object *obj, Visitor *v, void *opaque,
const char *name, Error **errp)
{
BoolProperty *prop = opaque;
bool value;
value = prop->get(obj, errp);
visit_type_bool(v, &value, name, errp);
}
| {
"code": [
" value = prop->get(obj, errp);",
" value = prop->get(obj, errp);"
],
"line_no": [
13,
13
]
} | static void FUNC_0(Object *VAR_0, Visitor *VAR_1, void *VAR_2,
const char *VAR_3, Error **VAR_4)
{
BoolProperty *prop = VAR_2;
bool value;
value = prop->get(VAR_0, VAR_4);
visit_type_bool(VAR_1, &value, VAR_3, VAR_4);
}
| [
"static void FUNC_0(Object *VAR_0, Visitor *VAR_1, void *VAR_2,\nconst char *VAR_3, Error **VAR_4)\n{",
"BoolProperty *prop = VAR_2;",
"bool value;",
"value = prop->get(VAR_0, VAR_4);",
"visit_type_bool(VAR_1, &value, VAR_3, VAR_4);",
"}"
] | [
0,
0,
0,
1,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
17
]
] |
4,582 | static int read_header(ShortenContext *s)
{
int i, ret;
int maxnlpc = 0;
/* shorten signature */
if (get_bits_long(&s->gb, 32) != AV_RB32("ajkg")) {
av_log(s->avctx, AV_LOG_ERROR, "missing shorten magic 'ajkg'\n");
s->lpcqoffset = 0;
s->blocksize = DEFAULT_BLOCK_SIZE... | true | FFmpeg | e77ddd31a8e14bcf5eccd6008d866ae90b4b0d4c | static int read_header(ShortenContext *s)
{
int i, ret;
int maxnlpc = 0;
if (get_bits_long(&s->gb, 32) != AV_RB32("ajkg")) {
av_log(s->avctx, AV_LOG_ERROR, "missing shorten magic 'ajkg'\n");
s->lpcqoffset = 0;
s->blocksize = DEFAULT_BLOCK_SIZE;
s->nmean ... | {
"code": [],
"line_no": []
} | static int FUNC_0(ShortenContext *VAR_0)
{
int VAR_1, VAR_2;
int VAR_3 = 0;
if (get_bits_long(&VAR_0->gb, 32) != AV_RB32("ajkg")) {
av_log(VAR_0->avctx, AV_LOG_ERROR, "missing shorten magic 'ajkg'\n");
VAR_0->lpcqoffset = 0;
VAR_0->VAR_5 = DEFAULT_BLOCK_SIZE;
V... | [
"static int FUNC_0(ShortenContext *VAR_0)\n{",
"int VAR_1, VAR_2;",
"int VAR_3 = 0;",
"if (get_bits_long(&VAR_0->gb, 32) != AV_RB32(\"ajkg\")) {",
"av_log(VAR_0->avctx, AV_LOG_ERROR, \"missing shorten magic 'ajkg'\\n\");",
"VAR_0->lpcqoffset = 0;",
"VAR_0->VAR_5 = DEFAULT_BLOCK_SIZE;",
"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,
0,
0,
0,
0,
0,
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
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
31
],
[
33
],
[
35
],
[
39
],
[
41
],
[
43
],
[
47
],
[
53
],
[
55
],
[
57... |
4,584 | int avcodec_get_pix_fmt_loss(enum PixelFormat dst_pix_fmt, enum PixelFormat src_pix_fmt,
int has_alpha)
{
const PixFmtInfo *pf, *ps;
const AVPixFmtDescriptor *src_desc = &av_pix_fmt_descriptors[src_pix_fmt];
const AVPixFmtDescriptor *dst_desc = &av_pix_fmt_descriptors[dst_p... | false | FFmpeg | d7e14c0d103a2c9cca6c50568e09b40d6f48ea19 | int avcodec_get_pix_fmt_loss(enum PixelFormat dst_pix_fmt, enum PixelFormat src_pix_fmt,
int has_alpha)
{
const PixFmtInfo *pf, *ps;
const AVPixFmtDescriptor *src_desc = &av_pix_fmt_descriptors[src_pix_fmt];
const AVPixFmtDescriptor *dst_desc = &av_pix_fmt_descriptors[dst_p... | {
"code": [],
"line_no": []
} | int FUNC_0(enum PixelFormat VAR_0, enum PixelFormat VAR_1,
int VAR_2)
{
const PixFmtInfo *VAR_3, *ps;
const AVPixFmtDescriptor *VAR_4 = &av_pix_fmt_descriptors[VAR_1];
const AVPixFmtDescriptor *VAR_5 = &av_pix_fmt_descriptors[VAR_0];
int VAR_6;
ps = &pix_fmt_inf... | [
"int FUNC_0(enum PixelFormat VAR_0, enum PixelFormat VAR_1,\nint VAR_2)\n{",
"const PixFmtInfo *VAR_3, *ps;",
"const AVPixFmtDescriptor *VAR_4 = &av_pix_fmt_descriptors[VAR_1];",
"const AVPixFmtDescriptor *VAR_5 = &av_pix_fmt_descriptors[VAR_0];",
"int VAR_6;",
"ps = &pix_fmt_info[VAR_1];",
"VAR_6 = 0;"... | [
0,
0,
0,
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
],
[
23
],
[
25
],
[
27,
29,
31,
33,
35,
37
],
[
39,
41,
43
],
[
45
],
[
47,
49,
51,
53
],
[
55
],
[
57,
59,... |
4,585 | static void svq1_parse_string(GetBitContext *bitbuf, uint8_t *out)
{
uint8_t seed;
int i;
out[0] = get_bits(bitbuf, 8);
seed = string_table[out[0]];
for (i = 1; i <= out[0]; i++) {
out[i] = get_bits(bitbuf, 8) ^ seed;
seed = string_table[out[i] ^ seed];
}
}
| false | FFmpeg | e91ba2efa949470e9157b652535d207a101f91e0 | static void svq1_parse_string(GetBitContext *bitbuf, uint8_t *out)
{
uint8_t seed;
int i;
out[0] = get_bits(bitbuf, 8);
seed = string_table[out[0]];
for (i = 1; i <= out[0]; i++) {
out[i] = get_bits(bitbuf, 8) ^ seed;
seed = string_table[out[i] ^ seed];
}
}
| {
"code": [],
"line_no": []
} | static void FUNC_0(GetBitContext *VAR_0, uint8_t *VAR_1)
{
uint8_t seed;
int VAR_2;
VAR_1[0] = get_bits(VAR_0, 8);
seed = string_table[VAR_1[0]];
for (VAR_2 = 1; VAR_2 <= VAR_1[0]; VAR_2++) {
VAR_1[VAR_2] = get_bits(VAR_0, 8) ^ seed;
seed = string_table[VAR_1[VAR_2] ^... | [
"static void FUNC_0(GetBitContext *VAR_0, uint8_t *VAR_1)\n{",
"uint8_t seed;",
"int VAR_2;",
"VAR_1[0] = get_bits(VAR_0, 8);",
"seed = string_table[VAR_1[0]];",
"for (VAR_2 = 1; VAR_2 <= VAR_1[0]; VAR_2++) {",
"VAR_1[VAR_2] = get_bits(VAR_0, 8) ^ seed;",
"seed = string_table[VAR_1[VAR_2] ^ seed];... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
13
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
]
] |
4,586 | static int vda_h264_end_frame(AVCodecContext *avctx)
{
H264Context *h = avctx->priv_data;
VDAContext *vda = avctx->internal->hwaccel_priv_data;
AVVDAContext *vda_ctx = avctx->hwaccel_context;
AVFrame *frame = h->cur_pic_ptr->f;
uint32_t flush_flags = 1 << 0; ///< kVDADecod... | false | FFmpeg | 80f955c90867561dcce769216bc497e13281eb38 | static int vda_h264_end_frame(AVCodecContext *avctx)
{
H264Context *h = avctx->priv_data;
VDAContext *vda = avctx->internal->hwaccel_priv_data;
AVVDAContext *vda_ctx = avctx->hwaccel_context;
AVFrame *frame = h->cur_pic_ptr->f;
uint32_t flush_flags = 1 << 0;
CFDataRe... | {
"code": [],
"line_no": []
} | static int FUNC_0(AVCodecContext *VAR_0)
{
H264Context *h = VAR_0->priv_data;
VDAContext *vda = VAR_0->internal->hwaccel_priv_data;
AVVDAContext *vda_ctx = VAR_0->hwaccel_context;
AVFrame *frame = h->cur_pic_ptr->f;
uint32_t flush_flags = 1 << 0;
CFDataRef coded_fram... | [
"static int FUNC_0(AVCodecContext *VAR_0)\n{",
"H264Context *h = VAR_0->priv_data;",
"VDAContext *vda = VAR_0->internal->hwaccel_priv_data;",
"AVVDAContext *vda_ctx = VAR_0->hwaccel_context;",
"AVFrame *frame = h->cur_pic_ptr->f;",
"uint32_t flush_flags = 1 << 0;",
"CFDataRef coded_... | [
0,
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
],
[
29,
31,
33
],
[
37
],
[
41,
43
],
[
47
],
[
51,
53
],
[
57
],
[
59
],
[
61
],
[... |
4,587 | int img_pad(AVPicture *dst, const AVPicture *src, int height, int width,
int pix_fmt, int padtop, int padbottom, int padleft, int padright,
int *color)
{
uint8_t *optr, *iptr;
int y_shift;
int x_shift;
int yheight;
int i, y;
if (pix_fmt < 0 || pix_fmt >= PIX_FM... | false | FFmpeg | 79acfb0e133317c3a38c55b73c3b80f3212af2f9 | int img_pad(AVPicture *dst, const AVPicture *src, int height, int width,
int pix_fmt, int padtop, int padbottom, int padleft, int padright,
int *color)
{
uint8_t *optr, *iptr;
int y_shift;
int x_shift;
int yheight;
int i, y;
if (pix_fmt < 0 || pix_fmt >= PIX_FM... | {
"code": [],
"line_no": []
} | int FUNC_0(AVPicture *VAR_0, const AVPicture *VAR_1, int VAR_2, int VAR_3,
int VAR_4, int VAR_5, int VAR_6, int VAR_7, int VAR_8,
int *VAR_9)
{
uint8_t *optr, *iptr;
int VAR_10;
int VAR_11;
int VAR_12;
int VAR_13, VAR_14;
if (VAR_4 < 0 || VAR_4 >= PIX_FMT_NB ||... | [
"int FUNC_0(AVPicture *VAR_0, const AVPicture *VAR_1, int VAR_2, int VAR_3,\nint VAR_4, int VAR_5, int VAR_6, int VAR_7, int VAR_8,\nint *VAR_9)\n{",
"uint8_t *optr, *iptr;",
"int VAR_10;",
"int VAR_11;",
"int VAR_12;",
"int VAR_13, VAR_14;",
"if (VAR_4 < 0 || VAR_4 >= PIX_FMT_NB ||\n!is_yuv_planar(&pix... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
27
],
[
29
],
[
31
],
[
35
],
[
37,
39
],
[
41
],
[
45
],
[
47
],
[
49
],
[
51,
53
],
[... |
4,588 | void avfilter_draw_slice(AVFilterLink *link, int y, int h)
{
uint8_t *src[4], *dst[4];
int i, j, hsub, vsub;
/* copy the slice if needed for permission reasons */
if(link->srcpic) {
avcodec_get_chroma_sub_sample(link->format, &hsub, &vsub);
src[0] = link->srcpic-> data[0] + y ... | false | FFmpeg | 19dc71045d2833d2b3b77648608687eb687b4af1 | void avfilter_draw_slice(AVFilterLink *link, int y, int h)
{
uint8_t *src[4], *dst[4];
int i, j, hsub, vsub;
if(link->srcpic) {
avcodec_get_chroma_sub_sample(link->format, &hsub, &vsub);
src[0] = link->srcpic-> data[0] + y * link->srcpic-> linesize[0];
dst[0] = link-... | {
"code": [],
"line_no": []
} | void FUNC_0(AVFilterLink *VAR_0, int VAR_1, int VAR_2)
{
uint8_t *src[4], *dst[4];
int VAR_3, VAR_4, VAR_5, VAR_6;
if(VAR_0->srcpic) {
avcodec_get_chroma_sub_sample(VAR_0->format, &VAR_5, &VAR_6);
src[0] = VAR_0->srcpic-> data[0] + VAR_1 * VAR_0->srcpic-> linesize[0];
... | [
"void FUNC_0(AVFilterLink *VAR_0, int VAR_1, int VAR_2)\n{",
"uint8_t *src[4], *dst[4];",
"int VAR_3, VAR_4, VAR_5, VAR_6;",
"if(VAR_0->srcpic) {",
"avcodec_get_chroma_sub_sample(VAR_0->format, &VAR_5, &VAR_6);",
"src[0] = VAR_0->srcpic-> data[0] + VAR_1 * VAR_0->srcpic-> linesize[0];",
"dst[0] = 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,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
13
],
[
15
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47... |
4,589 | static int ff_sctp_send(int s, const void *msg, size_t len,
const struct sctp_sndrcvinfo *sinfo, int flags)
{
struct msghdr outmsg;
struct iovec iov;
outmsg.msg_name = NULL;
outmsg.msg_namelen = 0;
outmsg.msg_iov = &iov;
iov.iov_base = m... | false | FFmpeg | 8ef98855d25e457094468e2e1a79d9b10d6445b2 | static int ff_sctp_send(int s, const void *msg, size_t len,
const struct sctp_sndrcvinfo *sinfo, int flags)
{
struct msghdr outmsg;
struct iovec iov;
outmsg.msg_name = NULL;
outmsg.msg_namelen = 0;
outmsg.msg_iov = &iov;
iov.iov_base = m... | {
"code": [],
"line_no": []
} | static int FUNC_0(int VAR_0, const void *VAR_1, size_t VAR_2,
const struct sctp_sndrcvinfo *VAR_3, int VAR_4)
{
struct msghdr VAR_5;
struct iovec VAR_6;
VAR_5.msg_name = NULL;
VAR_5.msg_namelen = 0;
VAR_5.msg_iov = &VAR_6;
VAR_6.iov_base ... | [
"static int FUNC_0(int VAR_0, const void *VAR_1, size_t VAR_2,\nconst struct sctp_sndrcvinfo *VAR_3, int VAR_4)\n{",
"struct msghdr VAR_5;",
"struct iovec VAR_6;",
"VAR_5.msg_name = NULL;",
"VAR_5.msg_namelen = 0;",
"VAR_5.msg_iov = &VAR_6;",
"VAR_6.iov_base = VAR_1;",
"VAR_6.... | [
0,
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
],
[
29
],
[
31
],
[
33
],
[
37
],
[
39
],
[
41
],
[
45
],
[
47
],
[
49
],
[... |
4,590 | static int dxtory_decode_v1_420(AVCodecContext *avctx, AVFrame *pic,
const uint8_t *src, int src_size)
{
int h, w;
uint8_t *Y1, *Y2, *U, *V;
int ret;
if (src_size < avctx->width * avctx->height * 3LL / 2) {
av_log(avctx, AV_LOG_ERROR, "packet too small\n"... | false | FFmpeg | 9caa9414ccf2dcf8aee2695377dee830a5024c82 | static int dxtory_decode_v1_420(AVCodecContext *avctx, AVFrame *pic,
const uint8_t *src, int src_size)
{
int h, w;
uint8_t *Y1, *Y2, *U, *V;
int ret;
if (src_size < avctx->width * avctx->height * 3LL / 2) {
av_log(avctx, AV_LOG_ERROR, "packet too small\n"... | {
"code": [],
"line_no": []
} | static int FUNC_0(AVCodecContext *VAR_0, AVFrame *VAR_1,
const uint8_t *VAR_2, int VAR_3)
{
int VAR_4, VAR_5;
uint8_t *Y1, *Y2, *U, *V;
int VAR_6;
if (VAR_3 < VAR_0->width * VAR_0->height * 3LL / 2) {
av_log(VAR_0, AV_LOG_ERROR, "packet too small\n");
... | [
"static int FUNC_0(AVCodecContext *VAR_0, AVFrame *VAR_1,\nconst uint8_t *VAR_2, int VAR_3)\n{",
"int VAR_4, VAR_5;",
"uint8_t *Y1, *Y2, *U, *V;",
"int VAR_6;",
"if (VAR_3 < VAR_0->width * VAR_0->height * 3LL / 2) {",
"av_log(VAR_0, AV_LOG_ERROR, \"packet too small\\n\");",
"return AVERROR_INVALIDDATA;"... | [
0,
0,
0,
0,
0,
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
],
[
25
],
[
27,
29
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49
... |
4,591 | void ff_avg_h264_qpel16_mc13_msa(uint8_t *dst, const uint8_t *src,
ptrdiff_t stride)
{
avc_luma_hv_qrt_and_aver_dst_16x16_msa(src + stride - 2,
src - (stride * 2),
stride, dst, stride);
}
| false | FFmpeg | 1181d93231e9b807965724587d363c1cfd5a1d0d | void ff_avg_h264_qpel16_mc13_msa(uint8_t *dst, const uint8_t *src,
ptrdiff_t stride)
{
avc_luma_hv_qrt_and_aver_dst_16x16_msa(src + stride - 2,
src - (stride * 2),
stride, dst, stride);
}
| {
"code": [],
"line_no": []
} | void FUNC_0(uint8_t *VAR_0, const uint8_t *VAR_1,
ptrdiff_t VAR_2)
{
avc_luma_hv_qrt_and_aver_dst_16x16_msa(VAR_1 + VAR_2 - 2,
VAR_1 - (VAR_2 * 2),
VAR_2, VAR_0, VAR_2);
}
| [
"void FUNC_0(uint8_t *VAR_0, const uint8_t *VAR_1,\nptrdiff_t VAR_2)\n{",
"avc_luma_hv_qrt_and_aver_dst_16x16_msa(VAR_1 + VAR_2 - 2,\nVAR_1 - (VAR_2 * 2),\nVAR_2, VAR_0, VAR_2);",
"}"
] | [
0,
0,
0
] | [
[
1,
3,
5
],
[
7,
9,
11
],
[
13
]
] |
4,592 | void ff_hevc_hls_residual_coding(HEVCContext *s, int x0, int y0,
int log2_trafo_size, enum ScanType scan_idx,
int c_idx)
{
#define GET_COORD(offset, n) \
do { ... | false | FFmpeg | 9a3653c9ecc4bbbbb502513a70bccd4090ed12b0 | void ff_hevc_hls_residual_coding(HEVCContext *s, int x0, int y0,
int log2_trafo_size, enum ScanType scan_idx,
int c_idx)
{
#define GET_COORD(offset, n) \
do { ... | {
"code": [],
"line_no": []
} | void FUNC_0(HEVCContext *VAR_0, int VAR_1, int VAR_2,
int VAR_3, enum ScanType VAR_4,
int VAR_5)
{
#define GET_COORD(VAR_51, VAR_42) \
do { \
VAR_46... | [
"void FUNC_0(HEVCContext *VAR_0, int VAR_1, int VAR_2,\nint VAR_3, enum ScanType VAR_4,\nint VAR_5)\n{",
"#define GET_COORD(VAR_51, VAR_42) \\\ndo { \\",
"VAR_46 = (VAR_44 << 2) + scan_x_off[VAR_42]; \... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
29
],
[
31
],
[
33
],
[
37
],
[
39
],
[
43
],
[
47
],
[
49
],
[
51
],
[... |
4,593 | static int mov_write_sidx_tag(AVIOContext *pb,
MOVTrack *track, int ref_size, int total_sidx_size)
{
int64_t pos = avio_tell(pb), offset_pos, end_pos;
int64_t presentation_time, duration, offset;
int starts_with_SAP, i, entries;
if (track->entry) {
entries ... | true | FFmpeg | 8e34089e265a6b01e1e3301e8864439d26793753 | static int mov_write_sidx_tag(AVIOContext *pb,
MOVTrack *track, int ref_size, int total_sidx_size)
{
int64_t pos = avio_tell(pb), offset_pos, end_pos;
int64_t presentation_time, duration, offset;
int starts_with_SAP, i, entries;
if (track->entry) {
entries ... | {
"code": [],
"line_no": []
} | static int FUNC_0(AVIOContext *VAR_0,
MOVTrack *VAR_1, int VAR_2, int VAR_3)
{
int64_t pos = avio_tell(VAR_0), offset_pos, end_pos;
int64_t presentation_time, duration, offset;
int VAR_4, VAR_5, VAR_6;
if (VAR_1->entry) {
VAR_6 = 1;
presentation_ti... | [
"static int FUNC_0(AVIOContext *VAR_0,\nMOVTrack *VAR_1, int VAR_2, int VAR_3)\n{",
"int64_t pos = avio_tell(VAR_0), offset_pos, end_pos;",
"int64_t presentation_time, duration, offset;",
"int VAR_4, VAR_5, VAR_6;",
"if (VAR_1->entry) {",
"VAR_6 = 1;",
"presentation_time = VAR_1->start_dts + VAR_1->frag... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
47
],
[
49
],
[
53
],
[... |
4,595 | static uint64_t vfio_rtl8168_window_quirk_read(void *opaque,
hwaddr addr, unsigned size)
{
VFIOQuirk *quirk = opaque;
VFIOPCIDevice *vdev = quirk->vdev;
switch (addr) {
case 4: /* address */
if (quirk->data.flags) {
trace_vfio_... | true | qemu | d451008e0fdf7fb817c791397e7999d5f3687e58 | static uint64_t vfio_rtl8168_window_quirk_read(void *opaque,
hwaddr addr, unsigned size)
{
VFIOQuirk *quirk = opaque;
VFIOPCIDevice *vdev = quirk->vdev;
switch (addr) {
case 4:
if (quirk->data.flags) {
trace_vfio_rtl8168_windo... | {
"code": [
" if (quirk->data.flags) {",
" trace_vfio_rtl8168_window_quirk_read_fake(",
" memory_region_name(&quirk->mem),",
" vdev->vbasedev.name);",
" return quirk->data.address_match ^ 0x80000000U;",
" if (quirk->data... | static uint64_t FUNC_0(void *opaque,
hwaddr addr, unsigned size)
{
VFIOQuirk *quirk = opaque;
VFIOPCIDevice *vdev = quirk->vdev;
switch (addr) {
case 4:
if (quirk->data.flags) {
trace_vfio_rtl8168_window_quirk_read_fake(
... | [
"static uint64_t FUNC_0(void *opaque,\nhwaddr addr, unsigned size)\n{",
"VFIOQuirk *quirk = opaque;",
"VFIOPCIDevice *vdev = quirk->vdev;",
"switch (addr) {",
"case 4:\nif (quirk->data.flags) {",
"trace_vfio_rtl8168_window_quirk_read_fake(\nmemory_region_name(&quirk->mem),\nvdev->vbasedev.name);",
"retu... | [
0,
0,
0,
0,
1,
1,
1,
0,
0,
0,
1,
1,
1,
1,
0,
1,
1,
0,
0,
1,
1,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
13
],
[
15,
17
],
[
19,
21,
23
],
[
27
],
[
29
],
[
31
],
[
33,
35
],
[
37
],
[
41,
43,
45
],
[
49
],
[
51
],
[
53
],
[
57,
59,... |
4,596 | static int teletext_decode_frame(AVCodecContext *avctx, void *data, int *data_size, AVPacket *pkt)
{
TeletextContext *ctx = avctx->priv_data;
AVSubtitle *sub = data;
const uint8_t *buf = pkt->data;
int left = pkt->size;
uint8_t pesheader[45] = {0x00, 0x00, 0x01, 0xbd... | true | FFmpeg | 085ca7dcdbf9ab6c23e3a5397b1f6d4aa23f763d | static int teletext_decode_frame(AVCodecContext *avctx, void *data, int *data_size, AVPacket *pkt)
{
TeletextContext *ctx = avctx->priv_data;
AVSubtitle *sub = data;
const uint8_t *buf = pkt->data;
int left = pkt->size;
uint8_t pesheader[45] = {0x00, 0x00, 0x01, 0xbd... | {
"code": [
" const uint8_t *buf = pkt->data;",
" int left = pkt->size;",
" uint8_t pesheader[45] = {0x00, 0x00, 0x01, 0xbd, 0x00, 0x00, 0x85, 0x80, 0x24, 0x21, 0x00, 0x01, 0x00, 0x01};",
" int pesheader_size = sizeof(pesheader);",
" const uint8_t ... | static int FUNC_0(AVCodecContext *VAR_0, void *VAR_1, int *VAR_2, AVPacket *VAR_3)
{
TeletextContext *ctx = VAR_0->priv_data;
AVSubtitle *sub = VAR_1;
const uint8_t *VAR_4 = VAR_3->VAR_1;
int VAR_5 = VAR_3->size;
uint8_t pesheader[45] = {0x00, 0x00, 0x01, 0xbd, 0x00,... | [
"static int FUNC_0(AVCodecContext *VAR_0, void *VAR_1, int *VAR_2, AVPacket *VAR_3)\n{",
"TeletextContext *ctx = VAR_0->priv_data;",
"AVSubtitle *sub = VAR_1;",
"const uint8_t *VAR_4 = VAR_3->VAR_1;",
"int VAR_5 = VAR_3->size;",
"uint8_t pesheader[45] = {0x00, 0x00, 0x01, 0xbd, ... | [
0,
0,
0,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
1,
1,
1,
1,
1,
0,
1,
1,
1,
1,
0,
1,
1,
1,
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... | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
23
],
[
25,
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41,
43
],
[
47,... |
4,597 | static int enable_write_target(BlockDriverState *bs, Error **errp)
{
BDRVVVFATState *s = bs->opaque;
BlockDriver *bdrv_qcow = NULL;
BlockDriverState *backing;
QemuOpts *opts = NULL;
int ret;
int size = sector2cluster(s, s->sector_count);
QDict *options;
s->used_clusters = call... | true | qemu | a8a4d15c1c34d3cec704fb64eba4a3745a140a97 | static int enable_write_target(BlockDriverState *bs, Error **errp)
{
BDRVVVFATState *s = bs->opaque;
BlockDriver *bdrv_qcow = NULL;
BlockDriverState *backing;
QemuOpts *opts = NULL;
int ret;
int size = sector2cluster(s, s->sector_count);
QDict *options;
s->used_clusters = call... | {
"code": [
" backing = bdrv_new();",
" s->bs->backing->bs->drv = &vvfat_write_target;",
" s->bs->backing->bs->opaque = g_new(void *, 1);",
" *(void**)s->bs->backing->bs->opaque = s;"
],
"line_no": [
107,
115,
117,
119
]
} | static int FUNC_0(BlockDriverState *VAR_0, Error **VAR_1)
{
BDRVVVFATState *s = VAR_0->opaque;
BlockDriver *bdrv_qcow = NULL;
BlockDriverState *backing;
QemuOpts *opts = NULL;
int VAR_2;
int VAR_3 = sector2cluster(s, s->sector_count);
QDict *options;
s->used_clusters = calloc(... | [
"static int FUNC_0(BlockDriverState *VAR_0, Error **VAR_1)\n{",
"BDRVVVFATState *s = VAR_0->opaque;",
"BlockDriver *bdrv_qcow = NULL;",
"BlockDriverState *backing;",
"QemuOpts *opts = NULL;",
"int VAR_2;",
"int VAR_3 = sector2cluster(s, s->sector_count);",
"QDict *options;",
"s->used_clusters = call... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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,
1,
1,
1,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
21
],
[
25
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
43
],
[
45
],
[
47
],
[
49
... |
4,601 | static int apng_read_header(AVFormatContext *s)
{
APNGDemuxContext *ctx = s->priv_data;
AVIOContext *pb = s->pb;
uint32_t len, tag;
AVStream *st;
int acTL_found = 0;
int64_t ret = AVERROR_INVALIDDATA;
/* verify PNGSIG */
if (avio_rb64(pb) != PNGSIG)
return ret;
... | true | FFmpeg | 16c429166ddf1736972b6ccce84bd3509ec16a34 | static int apng_read_header(AVFormatContext *s)
{
APNGDemuxContext *ctx = s->priv_data;
AVIOContext *pb = s->pb;
uint32_t len, tag;
AVStream *st;
int acTL_found = 0;
int64_t ret = AVERROR_INVALIDDATA;
if (avio_rb64(pb) != PNGSIG)
return ret;
len = avio_r... | {
"code": [
" ctx->extra_data = av_malloc(len + 12 + AV_INPUT_BUFFER_PADDING_SIZE);",
" if (!ctx->extra_data)",
" ctx->extra_data_size = len + 12;",
" AV_WB32(ctx->extra_data, len);",
" AV_WL32(ctx->extra_data+4, tag);",
" AV_WB32(ctx->extra_data+8, st->codecpar->width);... | static int FUNC_0(AVFormatContext *VAR_0)
{
APNGDemuxContext *ctx = VAR_0->priv_data;
AVIOContext *pb = VAR_0->pb;
uint32_t len, tag;
AVStream *st;
int VAR_1 = 0;
int64_t ret = AVERROR_INVALIDDATA;
if (avio_rb64(pb) != PNGSIG)
return ret;
len = avio_rb32... | [
"static int FUNC_0(AVFormatContext *VAR_0)\n{",
"APNGDemuxContext *ctx = VAR_0->priv_data;",
"AVIOContext *pb = VAR_0->pb;",
"uint32_t len, tag;",
"AVStream *st;",
"int VAR_1 = 0;",
"int64_t ret = AVERROR_INVALIDDATA;",
"if (avio_rb64(pb) != PNGSIG)\nreturn ret;",
"len = avio_rb32(pb);",
"tag = av... | [
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
1,
1,
1,
1,
1,
1,
1,
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... | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
21,
23
],
[
29
],
[
31
],
[
33,
35
],
[
39
],
[
41,
43
],
[
51
],
[
53
],
[
55
],
[
57
],
[
59
],
[... |
4,602 | static int local_statfs(FsContext *s, V9fsPath *fs_path, struct statfs *stbuf)
{
char *buffer;
int ret;
char *path = fs_path->data;
buffer = rpath(s, path);
ret = statfs(buffer, stbuf);
g_free(buffer);
return ret;
}
| true | qemu | 31e51d1c15b35dc98b88a301812914b70a2b55dc | static int local_statfs(FsContext *s, V9fsPath *fs_path, struct statfs *stbuf)
{
char *buffer;
int ret;
char *path = fs_path->data;
buffer = rpath(s, path);
ret = statfs(buffer, stbuf);
g_free(buffer);
return ret;
}
| {
"code": [
" char *buffer;",
" int ret;",
" char *path = fs_path->data;",
" buffer = rpath(s, path);",
" ret = statfs(buffer, stbuf);",
" g_free(buffer);"
],
"line_no": [
5,
7,
9,
13,
15,
17
]
} | static int FUNC_0(FsContext *VAR_0, V9fsPath *VAR_1, struct statfs *VAR_2)
{
char *VAR_3;
int VAR_4;
char *VAR_5 = VAR_1->data;
VAR_3 = rpath(VAR_0, VAR_5);
VAR_4 = statfs(VAR_3, VAR_2);
g_free(VAR_3);
return VAR_4;
}
| [
"static int FUNC_0(FsContext *VAR_0, V9fsPath *VAR_1, struct statfs *VAR_2)\n{",
"char *VAR_3;",
"int VAR_4;",
"char *VAR_5 = VAR_1->data;",
"VAR_3 = rpath(VAR_0, VAR_5);",
"VAR_4 = statfs(VAR_3, VAR_2);",
"g_free(VAR_3);",
"return VAR_4;",
"}"
] | [
0,
1,
1,
1,
1,
1,
1,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
]
] |
4,603 | int av_image_fill_black(uint8_t *dst_data[4], const ptrdiff_t dst_linesize[4],
enum AVPixelFormat pix_fmt, enum AVColorRange range,
int width, int height)
{
const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(pix_fmt);
int nb_planes = av_pix_fmt_count_planes... | true | FFmpeg | 0f5576a22b11ef726a01b14d1eaae2fa780c2f52 | int av_image_fill_black(uint8_t *dst_data[4], const ptrdiff_t dst_linesize[4],
enum AVPixelFormat pix_fmt, enum AVColorRange range,
int width, int height)
{
const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(pix_fmt);
int nb_planes = av_pix_fmt_count_planes... | {
"code": [],
"line_no": []
} | int FUNC_0(uint8_t *VAR_0[4], const ptrdiff_t VAR_1[4],
enum AVPixelFormat VAR_2, enum AVColorRange VAR_3,
int VAR_4, int VAR_5)
{
const AVPixFmtDescriptor *VAR_6 = av_pix_fmt_desc_get(VAR_2);
int VAR_7 = av_pix_fmt_count_planes(VAR_2);
uint8... | [
"int FUNC_0(uint8_t *VAR_0[4], const ptrdiff_t VAR_1[4],\nenum AVPixelFormat VAR_2, enum AVColorRange VAR_3,\nint VAR_4, int VAR_5)\n{",
"const AVPixFmtDescriptor *VAR_6 = av_pix_fmt_desc_get(VAR_2);",
"int VAR_7 = av_pix_fmt_count_planes(VAR_2);",
"uint8_t clear_block[4][MAX_BLOCK_SIZE] = {0};",
"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,
0,
0,
0,
0,
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
],
[
23
],
[
25
],
[
29,
31
],
[
35
],
[
37
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49
],
[
51,
53
],
[
57,... |
4,604 | bool cache_is_cached(const PageCache *cache, uint64_t addr)
{
size_t pos;
g_assert(cache);
g_assert(cache->page_cache);
pos = cache_get_cache_pos(cache, addr);
return (cache->page_cache[pos].it_addr == addr);
}
| true | qemu | 27af7d6ea5015e5ef1f7985eab94a8a218267a2b | bool cache_is_cached(const PageCache *cache, uint64_t addr)
{
size_t pos;
g_assert(cache);
g_assert(cache->page_cache);
pos = cache_get_cache_pos(cache, addr);
return (cache->page_cache[pos].it_addr == addr);
}
| {
"code": [
"bool cache_is_cached(const PageCache *cache, uint64_t addr)",
" return (cache->page_cache[pos].it_addr == addr);"
],
"line_no": [
1,
19
]
} | bool FUNC_0(const PageCache *cache, uint64_t addr)
{
size_t pos;
g_assert(cache);
g_assert(cache->page_cache);
pos = cache_get_cache_pos(cache, addr);
return (cache->page_cache[pos].it_addr == addr);
}
| [
"bool FUNC_0(const PageCache *cache, uint64_t addr)\n{",
"size_t pos;",
"g_assert(cache);",
"g_assert(cache->page_cache);",
"pos = cache_get_cache_pos(cache, addr);",
"return (cache->page_cache[pos].it_addr == addr);",
"}"
] | [
1,
0,
0,
0,
0,
1,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
],
[
15
],
[
19
],
[
21
]
] |
4,605 | static void superio_ioport_writeb(void *opaque, hwaddr addr, uint64_t data,
unsigned size)
{
int can_write;
SuperIOConfig *superio_conf = opaque;
DPRINTF("superio_ioport_writeb address 0x%x val 0x%x\n", addr, data);
if (addr == 0x3f0) {
superio_conf->... | true | qemu | b196d969efa3987148994f0f8da79a10ebda7641 | static void superio_ioport_writeb(void *opaque, hwaddr addr, uint64_t data,
unsigned size)
{
int can_write;
SuperIOConfig *superio_conf = opaque;
DPRINTF("superio_ioport_writeb address 0x%x val 0x%x\n", addr, data);
if (addr == 0x3f0) {
superio_conf->... | {
"code": [
" int can_write;",
" can_write = 0;",
" default:",
" can_write = 1;",
" if (can_write) {",
" switch (superio_conf->index) {",
" case 0xe7:",
" if ((data & 0xff) != 0xfe) {",
" ... | static void FUNC_0(void *VAR_0, hwaddr VAR_1, uint64_t VAR_2,
unsigned VAR_3)
{
int VAR_4;
SuperIOConfig *superio_conf = VAR_0;
DPRINTF("FUNC_0 address 0x%x val 0x%x\n", VAR_1, VAR_2);
if (VAR_1 == 0x3f0) {
superio_conf->index = VAR_2 & 0xff;
} e... | [
"static void FUNC_0(void *VAR_0, hwaddr VAR_1, uint64_t VAR_2,\nunsigned VAR_3)\n{",
"int VAR_4;",
"SuperIOConfig *superio_conf = VAR_0;",
"DPRINTF(\"FUNC_0 address 0x%x val 0x%x\\n\", VAR_1, VAR_2);",
"if (VAR_1 == 0x3f0) {",
"superio_conf->index = VAR_2 & 0xff;",
"} else {",
"switch (superio_conf-... | [
0,
1,
0,
0,
0,
0,
0,
0,
1,
0,
1,
1,
1,
1,
1,
0,
1,
1,
1,
0,
0,
1,
0,
0,
0,
1,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
17
],
[
19
],
[
23
],
[
25,
27,
29,
31,
33,
35,
37,
39,
41,
43
],
[
45
],
[
47,
49
],
[
53
],
[
55
],
[
57,
59
... |
4,608 | static int default_fdset_get_fd(int64_t fdset_id, int flags)
{
return -1;
}
| false | qemu | 1f001dc7bc9e435bf231a5b0edcad1c7c2bd6214 | static int default_fdset_get_fd(int64_t fdset_id, int flags)
{
return -1;
}
| {
"code": [],
"line_no": []
} | static int FUNC_0(int64_t VAR_0, int VAR_1)
{
return -1;
}
| [
"static int FUNC_0(int64_t VAR_0, int VAR_1)\n{",
"return -1;",
"}"
] | [
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
]
] |
4,613 | static void virtio_scsi_fail_cmd_req(VirtIOSCSIReq *req)
{
req->resp.cmd->response = VIRTIO_SCSI_S_FAILURE;
virtio_scsi_complete_cmd_req(req);
}
| false | qemu | 3eff1f46f08a360a4ae9f834ce9fef4c45bf6f0f | static void virtio_scsi_fail_cmd_req(VirtIOSCSIReq *req)
{
req->resp.cmd->response = VIRTIO_SCSI_S_FAILURE;
virtio_scsi_complete_cmd_req(req);
}
| {
"code": [],
"line_no": []
} | static void FUNC_0(VirtIOSCSIReq *VAR_0)
{
VAR_0->resp.cmd->response = VIRTIO_SCSI_S_FAILURE;
virtio_scsi_complete_cmd_req(VAR_0);
}
| [
"static void FUNC_0(VirtIOSCSIReq *VAR_0)\n{",
"VAR_0->resp.cmd->response = VIRTIO_SCSI_S_FAILURE;",
"virtio_scsi_complete_cmd_req(VAR_0);",
"}"
] | [
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
]
] |
4,614 | static int iscsi_open(BlockDriverState *bs, QDict *options, int flags,
Error **errp)
{
IscsiLun *iscsilun = bs->opaque;
struct iscsi_context *iscsi = NULL;
struct iscsi_url *iscsi_url = NULL;
struct scsi_task *task = NULL;
struct scsi_inquiry_standard *inq = NULL;
s... | false | qemu | 43ae8fb10c5f6ca78f242624c1f446e0050a9d43 | static int iscsi_open(BlockDriverState *bs, QDict *options, int flags,
Error **errp)
{
IscsiLun *iscsilun = bs->opaque;
struct iscsi_context *iscsi = NULL;
struct iscsi_url *iscsi_url = NULL;
struct scsi_task *task = NULL;
struct scsi_inquiry_standard *inq = NULL;
s... | {
"code": [],
"line_no": []
} | static int FUNC_0(BlockDriverState *VAR_0, QDict *VAR_1, int VAR_2,
Error **VAR_3)
{
IscsiLun *iscsilun = VAR_0->opaque;
struct iscsi_context *VAR_4 = NULL;
struct VAR_5 *VAR_5 = NULL;
struct scsi_task *VAR_6 = NULL;
struct scsi_inquiry_standard *VAR_7 = NULL;
struc... | [
"static int FUNC_0(BlockDriverState *VAR_0, QDict *VAR_1, int VAR_2,\nError **VAR_3)\n{",
"IscsiLun *iscsilun = VAR_0->opaque;",
"struct iscsi_context *VAR_4 = NULL;",
"struct VAR_5 *VAR_5 = NULL;",
"struct scsi_task *VAR_6 = NULL;",
"struct scsi_inquiry_standard *VAR_7 = NULL;",
"struct scsi_inquiry_su... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
25
],
[
27
],
[
31
],
[
33,
35,
37
],
[
39
],
[
41
],
[
45
],
[
47
],
[... |
4,616 | static void string_output_append_range(StringOutputVisitor *sov,
int64_t s, int64_t e)
{
Range *r = g_malloc0(sizeof(*r));
r->begin = s;
r->end = e + 1;
sov->ranges = range_list_insert(sov->ranges, r);
}
| false | qemu | a0efbf16604770b9d805bcf210ec29942321134f | static void string_output_append_range(StringOutputVisitor *sov,
int64_t s, int64_t e)
{
Range *r = g_malloc0(sizeof(*r));
r->begin = s;
r->end = e + 1;
sov->ranges = range_list_insert(sov->ranges, r);
}
| {
"code": [],
"line_no": []
} | static void FUNC_0(StringOutputVisitor *VAR_0,
int64_t VAR_1, int64_t VAR_2)
{
Range *r = g_malloc0(sizeof(*r));
r->begin = VAR_1;
r->end = VAR_2 + 1;
VAR_0->ranges = range_list_insert(VAR_0->ranges, r);
}
| [
"static void FUNC_0(StringOutputVisitor *VAR_0,\nint64_t VAR_1, int64_t VAR_2)\n{",
"Range *r = g_malloc0(sizeof(*r));",
"r->begin = VAR_1;",
"r->end = VAR_2 + 1;",
"VAR_0->ranges = range_list_insert(VAR_0->ranges, r);",
"}"
] | [
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
]
] |
4,617 | static int coroutine_fn iscsi_co_readv(BlockDriverState *bs,
int64_t sector_num, int nb_sectors,
QEMUIOVector *iov)
{
IscsiLun *iscsilun = bs->opaque;
struct IscsiTask iTask;
uint64_t lba;
uint32_t num_sectors;
i... | false | qemu | e1123a3b40a1a9a625a29c8ed4debb7e206ea690 | static int coroutine_fn iscsi_co_readv(BlockDriverState *bs,
int64_t sector_num, int nb_sectors,
QEMUIOVector *iov)
{
IscsiLun *iscsilun = bs->opaque;
struct IscsiTask iTask;
uint64_t lba;
uint32_t num_sectors;
i... | {
"code": [],
"line_no": []
} | static int VAR_0 iscsi_co_readv(BlockDriverState *bs,
int64_t sector_num, int nb_sectors,
QEMUIOVector *iov)
{
IscsiLun *iscsilun = bs->opaque;
struct IscsiTask iTask;
uint64_t lba;
uint32_t num_sectors;
if (!is_... | [
"static int VAR_0 iscsi_co_readv(BlockDriverState *bs,\nint64_t sector_num, int nb_sectors,\nQEMUIOVector *iov)\n{",
"IscsiLun *iscsilun = bs->opaque;",
"struct IscsiTask iTask;",
"uint64_t lba;",
"uint32_t num_sectors;",
"if (!is_sector_request_lun_aligned(sector_num, nb_sectors, iscsilun)) {",
"return... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
27,
29
],
[
31,
33
],
[
35
],
[
37
],
[
41,
43
],
[
45
],
[
47
],
[
49
],
[
51,
53
... |
4,618 | static DeviceClass *qdev_get_device_class(const char **driver, Error **errp)
{
ObjectClass *oc;
DeviceClass *dc;
oc = object_class_by_name(*driver);
if (!oc) {
const char *typename = find_typename_by_alias(*driver);
if (typename) {
*driver = typename;
... | false | qemu | f6b5319d412cda360695e2005737f91ca8201af0 | static DeviceClass *qdev_get_device_class(const char **driver, Error **errp)
{
ObjectClass *oc;
DeviceClass *dc;
oc = object_class_by_name(*driver);
if (!oc) {
const char *typename = find_typename_by_alias(*driver);
if (typename) {
*driver = typename;
... | {
"code": [],
"line_no": []
} | static DeviceClass *FUNC_0(const char **driver, Error **errp)
{
ObjectClass *oc;
DeviceClass *dc;
oc = object_class_by_name(*driver);
if (!oc) {
const char *VAR_0 = find_typename_by_alias(*driver);
if (VAR_0) {
*driver = VAR_0;
oc = object_class_by_na... | [
"static DeviceClass *FUNC_0(const char **driver, Error **errp)\n{",
"ObjectClass *oc;",
"DeviceClass *dc;",
"oc = object_class_by_name(*driver);",
"if (!oc) {",
"const char *VAR_0 = find_typename_by_alias(*driver);",
"if (VAR_0) {",
"*driver = VAR_0;",
"oc = object_class_by_name(*driver);",
"}",
... | [
0,
0,
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
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
31
],
[
33
],
[
35
],
[
37
],
[
41
],
[
43,
45
],
[
47
],
[
49
],
... |
4,619 | static int usb_net_handle_control(USBDevice *dev, int request, int value,
int index, int length, uint8_t *data)
{
USBNetState *s = (USBNetState *) dev;
int ret = 0;
switch(request) {
case DeviceRequest | USB_REQ_GET_STATUS:
data[0] = (1 << USB_DEVICE_SELF_POWERED) |
... | false | qemu | d59f8ba938afd837182e666cce777dfb860559e4 | static int usb_net_handle_control(USBDevice *dev, int request, int value,
int index, int length, uint8_t *data)
{
USBNetState *s = (USBNetState *) dev;
int ret = 0;
switch(request) {
case DeviceRequest | USB_REQ_GET_STATUS:
data[0] = (1 << USB_DEVICE_SELF_POWERED) |
... | {
"code": [],
"line_no": []
} | static int FUNC_0(USBDevice *VAR_0, int VAR_1, int VAR_2,
int VAR_3, int VAR_4, uint8_t *VAR_5)
{
USBNetState *s = (USBNetState *) VAR_0;
int VAR_6 = 0;
switch(VAR_1) {
case DeviceRequest | USB_REQ_GET_STATUS:
VAR_5[0] = (1 << USB_DEVICE_SELF_POWERED) |
... | [
"static int FUNC_0(USBDevice *VAR_0, int VAR_1, int VAR_2,\nint VAR_3, int VAR_4, uint8_t *VAR_5)\n{",
"USBNetState *s = (USBNetState *) VAR_0;",
"int VAR_6 = 0;",
"switch(VAR_1) {",
"case DeviceRequest | USB_REQ_GET_STATUS:\nVAR_5[0] = (1 << USB_DEVICE_SELF_POWERED) |\n(VAR_0->remote_wakeup << USB_DEVICE_R... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
29,
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
47,
49
],
[
51
],
[... |
4,620 | static void v9fs_synth_rewinddir(FsContext *ctx, V9fsFidOpenState *fs)
{
v9fs_synth_seekdir(ctx, fs, 0);
}
| false | qemu | 364031f17932814484657e5551ba12957d993d7e | static void v9fs_synth_rewinddir(FsContext *ctx, V9fsFidOpenState *fs)
{
v9fs_synth_seekdir(ctx, fs, 0);
}
| {
"code": [],
"line_no": []
} | static void FUNC_0(FsContext *VAR_0, V9fsFidOpenState *VAR_1)
{
v9fs_synth_seekdir(VAR_0, VAR_1, 0);
}
| [
"static void FUNC_0(FsContext *VAR_0, V9fsFidOpenState *VAR_1)\n{",
"v9fs_synth_seekdir(VAR_0, VAR_1, 0);",
"}"
] | [
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
]
] |
4,621 | void ff_vp3_h_loop_filter_c(uint8_t *first_pixel, int stride, int *bounding_values)
{
unsigned char *end;
int filter_value;
for (end= first_pixel + 8*stride; first_pixel != end; first_pixel += stride) {
filter_value =
(first_pixel[-2] - first_pixel[ 1])
+3*(first_pixel[... | false | FFmpeg | 28f9ab7029bd1a02f659995919f899f84ee7361b | void ff_vp3_h_loop_filter_c(uint8_t *first_pixel, int stride, int *bounding_values)
{
unsigned char *end;
int filter_value;
for (end= first_pixel + 8*stride; first_pixel != end; first_pixel += stride) {
filter_value =
(first_pixel[-2] - first_pixel[ 1])
+3*(first_pixel[... | {
"code": [],
"line_no": []
} | void FUNC_0(uint8_t *VAR_0, int VAR_1, int *VAR_2)
{
unsigned char *VAR_3;
int VAR_4;
for (VAR_3= VAR_0 + 8*VAR_1; VAR_0 != VAR_3; VAR_0 += VAR_1) {
VAR_4 =
(VAR_0[-2] - VAR_0[ 1])
+3*(VAR_0[ 0] - VAR_0[-1]);
VAR_4 = VAR_2[(VAR_4 + 4) >> 3];
VAR_0[-1] ... | [
"void FUNC_0(uint8_t *VAR_0, int VAR_1, int *VAR_2)\n{",
"unsigned char *VAR_3;",
"int VAR_4;",
"for (VAR_3= VAR_0 + 8*VAR_1; VAR_0 != VAR_3; VAR_0 += VAR_1) {",
"VAR_4 =\n(VAR_0[-2] - VAR_0[ 1])\n+3*(VAR_0[ 0] - VAR_0[-1]);",
"VAR_4 = VAR_2[(VAR_4 + 4) >> 3];",
"VAR_0[-1] = av_clip_uint8(VAR_0[-1] + VA... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
13,
15,
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
]
] |
4,622 | static int huffman_decode(MPADecodeContext *s, GranuleDef *g,
int16_t *exponents, int end_pos2)
{
int s_index;
int i;
int last_pos, bits_left;
VLC *vlc;
int end_pos = FFMIN(end_pos2, s->gb.size_in_bits);
/* low frequencies (called big values) */
s_index =... | false | FFmpeg | d2a0041c2075a553bb8d4f94591f8556680190c8 | static int huffman_decode(MPADecodeContext *s, GranuleDef *g,
int16_t *exponents, int end_pos2)
{
int s_index;
int i;
int last_pos, bits_left;
VLC *vlc;
int end_pos = FFMIN(end_pos2, s->gb.size_in_bits);
s_index = 0;
for (i = 0; i < 3; i++) {
... | {
"code": [],
"line_no": []
} | static int FUNC_0(MPADecodeContext *VAR_0, GranuleDef *VAR_1,
int16_t *VAR_2, int VAR_3)
{
int VAR_4;
int VAR_5;
int VAR_6, VAR_7;
VLC *vlc;
int VAR_8 = FFMIN(VAR_3, VAR_0->gb.size_in_bits);
VAR_4 = 0;
for (VAR_5 = 0; VAR_5 < 3; VAR_5++) {
... | [
"static int FUNC_0(MPADecodeContext *VAR_0, GranuleDef *VAR_1,\nint16_t *VAR_2, int VAR_3)\n{",
"int VAR_4;",
"int VAR_5;",
"int VAR_6, VAR_7;",
"VLC *vlc;",
"int VAR_8 = FFMIN(VAR_3, VAR_0->gb.size_in_bits);",
"VAR_4 = 0;",
"for (VAR_5 = 0; VAR_5 < 3; VAR_5++) {",
"int VAR_9, VAR_10, VAR_11, VAR_12... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29,
31
],
[
35
],
[
37
],
[
39
],
[
41
],
[
45
],
[
47
],
[
49
],
[
51
... |
4,623 | static void memory_region_write_thunk_n(void *_mr,
target_phys_addr_t addr,
unsigned size,
uint64_t data)
{
MemoryRegion *mr = _mr;
if (!memory_region_access_valid(mr, addr, size)) {
... | false | qemu | 897fa7cff21a98b260a5b3e73eae39273fa60272 | static void memory_region_write_thunk_n(void *_mr,
target_phys_addr_t addr,
unsigned size,
uint64_t data)
{
MemoryRegion *mr = _mr;
if (!memory_region_access_valid(mr, addr, size)) {
... | {
"code": [],
"line_no": []
} | static void FUNC_0(void *VAR_0,
target_phys_addr_t VAR_1,
unsigned VAR_2,
uint64_t VAR_3)
{
MemoryRegion *mr = VAR_0;
if (!memory_region_access_valid(mr, VAR_1, VAR_2)) {
retu... | [
"static void FUNC_0(void *VAR_0,\ntarget_phys_addr_t VAR_1,\nunsigned VAR_2,\nuint64_t VAR_3)\n{",
"MemoryRegion *mr = VAR_0;",
"if (!memory_region_access_valid(mr, VAR_1, VAR_2)) {",
"return;",
"}",
"if (!mr->ops->write) {",
"mr->ops->old_mmio.write[bitops_ffsl(VAR_2)](mr->opaque, VAR_1, VAR_3);",
"r... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5,
7,
9
],
[
11
],
[
15
],
[
17
],
[
19
],
[
23
],
[
25
],
[
27
],
[
29
],
[
35,
37,
39,
41
],
[
43
]
] |
4,624 | static int zipl_load_segment(struct component_entry *entry)
{
const int max_entries = (SECTOR_SIZE / sizeof(struct scsi_blockptr));
struct scsi_blockptr *bprs = (void*)sec;
const int bprs_size = sizeof(sec);
uint64_t blockno;
long address;
int i;
blockno = entry->data.blockno;
... | false | qemu | abd696e4f74a9d30801c6ae2693efe4e5979c2f2 | static int zipl_load_segment(struct component_entry *entry)
{
const int max_entries = (SECTOR_SIZE / sizeof(struct scsi_blockptr));
struct scsi_blockptr *bprs = (void*)sec;
const int bprs_size = sizeof(sec);
uint64_t blockno;
long address;
int i;
blockno = entry->data.blockno;
... | {
"code": [],
"line_no": []
} | static int FUNC_0(struct component_entry *VAR_0)
{
const int VAR_1 = (SECTOR_SIZE / sizeof(struct scsi_blockptr));
struct scsi_blockptr *VAR_2 = (void*)sec;
const int VAR_3 = sizeof(sec);
uint64_t blockno;
long VAR_4;
int VAR_5;
blockno = VAR_0->data.blockno;
VAR_4 = VAR_0->lo... | [
"static int FUNC_0(struct component_entry *VAR_0)\n{",
"const int VAR_1 = (SECTOR_SIZE / sizeof(struct scsi_blockptr));",
"struct scsi_blockptr *VAR_2 = (void*)sec;",
"const int VAR_3 = sizeof(sec);",
"uint64_t blockno;",
"long VAR_4;",
"int VAR_5;",
"blockno = VAR_0->data.blockno;",
"VAR_4 = 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,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
19
],
[
21
],
[
25
],
[
27
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
45
],
[
47
],
[
51
... |
4,625 | int event_notifier_set(EventNotifier *e)
{
uint64_t value = 1;
int r = write(e->fd, &value, sizeof(value));
return r == sizeof(value);
}
| false | qemu | d0cc2fbfa607678866475383c508be84818ceb64 | int event_notifier_set(EventNotifier *e)
{
uint64_t value = 1;
int r = write(e->fd, &value, sizeof(value));
return r == sizeof(value);
}
| {
"code": [],
"line_no": []
} | int FUNC_0(EventNotifier *VAR_0)
{
uint64_t value = 1;
int VAR_1 = write(VAR_0->fd, &value, sizeof(value));
return VAR_1 == sizeof(value);
}
| [
"int FUNC_0(EventNotifier *VAR_0)\n{",
"uint64_t value = 1;",
"int VAR_1 = write(VAR_0->fd, &value, sizeof(value));",
"return VAR_1 == sizeof(value);",
"}"
] | [
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
]
] |
4,626 | long do_sigreturn(CPUSPARCState *env)
{
abi_ulong sf_addr;
struct target_signal_frame *sf;
uint32_t up_psr, pc, npc;
target_sigset_t set;
sigset_t host_set;
int err=0, i;
sf_addr = env->regwptr[UREG_FP];
trace_user_do_sigreturn(env, sf_addr);
if (!lock_user_struct(VERIFY_... | false | qemu | c0bea68f9ea48f0dea7a06a259a613bfd3a7e35e | long do_sigreturn(CPUSPARCState *env)
{
abi_ulong sf_addr;
struct target_signal_frame *sf;
uint32_t up_psr, pc, npc;
target_sigset_t set;
sigset_t host_set;
int err=0, i;
sf_addr = env->regwptr[UREG_FP];
trace_user_do_sigreturn(env, sf_addr);
if (!lock_user_struct(VERIFY_... | {
"code": [],
"line_no": []
} | long FUNC_0(CPUSPARCState *VAR_0)
{
abi_ulong sf_addr;
struct target_signal_frame *VAR_1;
uint32_t up_psr, pc, npc;
target_sigset_t set;
sigset_t host_set;
int VAR_2=0, VAR_3;
sf_addr = VAR_0->regwptr[UREG_FP];
trace_user_do_sigreturn(VAR_0, sf_addr);
if (!lock_user_struc... | [
"long FUNC_0(CPUSPARCState *VAR_0)\n{",
"abi_ulong sf_addr;",
"struct target_signal_frame *VAR_1;",
"uint32_t up_psr, pc, npc;",
"target_sigset_t set;",
"sigset_t host_set;",
"int VAR_2=0, VAR_3;",
"sf_addr = VAR_0->regwptr[UREG_FP];",
"trace_user_do_sigreturn(VAR_0, sf_addr);",
"if (!lock_user_st... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
35,
37
],
[
41
],
[
43
],
[
47
],
[
49
],
[
51
],
[
57
],
[... |
4,627 | void qcow2_free_any_clusters(BlockDriverState *bs, uint64_t l2_entry,
int nb_clusters, enum qcow2_discard_type type)
{
BDRVQcow2State *s = bs->opaque;
switch (qcow2_get_cluster_type(l2_entry)) {
case QCOW2_CLUSTER_COMPRESSED:
{
int nb_csectors;
... | false | qemu | fdfab37dfeffefbd4533b4158055c9b82d7c3e69 | void qcow2_free_any_clusters(BlockDriverState *bs, uint64_t l2_entry,
int nb_clusters, enum qcow2_discard_type type)
{
BDRVQcow2State *s = bs->opaque;
switch (qcow2_get_cluster_type(l2_entry)) {
case QCOW2_CLUSTER_COMPRESSED:
{
int nb_csectors;
... | {
"code": [],
"line_no": []
} | void FUNC_0(BlockDriverState *VAR_0, uint64_t VAR_1,
int VAR_2, enum qcow2_discard_type VAR_3)
{
BDRVQcow2State *s = VAR_0->opaque;
switch (qcow2_get_cluster_type(VAR_1)) {
case QCOW2_CLUSTER_COMPRESSED:
{
int VAR_4;
VAR_4 = ((VAR_1 >> s... | [
"void FUNC_0(BlockDriverState *VAR_0, uint64_t VAR_1,\nint VAR_2, enum qcow2_discard_type VAR_3)\n{",
"BDRVQcow2State *s = VAR_0->opaque;",
"switch (qcow2_get_cluster_type(VAR_1)) {",
"case QCOW2_CLUSTER_COMPRESSED:\n{",
"int VAR_4;",
"VAR_4 = ((VAR_1 >> s->csize_shift) &\ns->csize_mask) + 1;",
"qcow2_f... | [
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
],
[
49,
51
],
[
53... |
4,628 | void qemu_put_byte(QEMUFile *f, int v)
{
if (!f->last_error && f->is_write == 0 && f->buf_index > 0) {
fprintf(stderr,
"Attempted to write to buffer while read buffer is not empty\n");
abort();
}
f->buf[f->buf_index++] = v;
f->is_write = 1;
if (f->buf_index... | false | qemu | c10682cb031525a8bdf3999ef6a033777929d304 | void qemu_put_byte(QEMUFile *f, int v)
{
if (!f->last_error && f->is_write == 0 && f->buf_index > 0) {
fprintf(stderr,
"Attempted to write to buffer while read buffer is not empty\n");
abort();
}
f->buf[f->buf_index++] = v;
f->is_write = 1;
if (f->buf_index... | {
"code": [],
"line_no": []
} | void FUNC_0(QEMUFile *VAR_0, int VAR_1)
{
if (!VAR_0->last_error && VAR_0->is_write == 0 && VAR_0->buf_index > 0) {
fprintf(stderr,
"Attempted to write to buffer while read buffer is not empty\n");
abort();
}
VAR_0->buf[VAR_0->buf_index++] = VAR_1;
VAR_0->is_wri... | [
"void FUNC_0(QEMUFile *VAR_0, int VAR_1)\n{",
"if (!VAR_0->last_error && VAR_0->is_write == 0 && VAR_0->buf_index > 0) {",
"fprintf(stderr,\n\"Attempted to write to buffer while read buffer is not empty\\n\");",
"abort();",
"}",
"VAR_0->buf[VAR_0->buf_index++] = VAR_1;",
"VAR_0->is_write = 1;",
"if (V... | [
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
]
] |
4,629 | static void n8x0_i2c_setup(struct n800_s *s)
{
DeviceState *dev;
qemu_irq tmp_irq = qdev_get_gpio_in(s->cpu->gpio, N8X0_TMP105_GPIO);
/* Attach the CPU on one end of our I2C bus. */
s->i2c = omap_i2c_bus(s->cpu->i2c[0]);
/* Attach a menelaus PM chip */
dev = i2c_create_slave(s->i2c, ... | false | qemu | 0919ac787641db11024912651f3bc5764d4f1286 | static void n8x0_i2c_setup(struct n800_s *s)
{
DeviceState *dev;
qemu_irq tmp_irq = qdev_get_gpio_in(s->cpu->gpio, N8X0_TMP105_GPIO);
s->i2c = omap_i2c_bus(s->cpu->i2c[0]);
dev = i2c_create_slave(s->i2c, "twl92230", N8X0_MENELAUS_ADDR);
qdev_connect_gpio_out(dev, 3, s->cpu->irq... | {
"code": [],
"line_no": []
} | static void FUNC_0(struct n800_s *VAR_0)
{
DeviceState *dev;
qemu_irq tmp_irq = qdev_get_gpio_in(VAR_0->cpu->gpio, N8X0_TMP105_GPIO);
VAR_0->i2c = omap_i2c_bus(VAR_0->cpu->i2c[0]);
dev = i2c_create_slave(VAR_0->i2c, "twl92230", N8X0_MENELAUS_ADDR);
qdev_connect_gpio_out(dev, 3,... | [
"static void FUNC_0(struct n800_s *VAR_0)\n{",
"DeviceState *dev;",
"qemu_irq tmp_irq = qdev_get_gpio_in(VAR_0->cpu->gpio, N8X0_TMP105_GPIO);",
"VAR_0->i2c = omap_i2c_bus(VAR_0->cpu->i2c[0]);",
"dev = i2c_create_slave(VAR_0->i2c, \"twl92230\", N8X0_MENELAUS_ADDR);",
"qdev_connect_gpio_out(dev, 3, VAR_0->c... | [
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
13
],
[
19
],
[
21
],
[
27
],
[
29
],
[
31
]
] |
4,630 | void destroy_bdrvs(dev_match_fn *match_fn, void *arg)
{
DriveInfo *dinfo;
struct BlockDriverState *bs;
TAILQ_FOREACH(dinfo, &drives, next) {
bs = dinfo->bdrv;
if (bs) {
if (bs->private && match_fn(bs->private, arg)) {
drive_uninit(bs);
b... | false | qemu | 72cf2d4f0e181d0d3a3122e04129c58a95da713e | void destroy_bdrvs(dev_match_fn *match_fn, void *arg)
{
DriveInfo *dinfo;
struct BlockDriverState *bs;
TAILQ_FOREACH(dinfo, &drives, next) {
bs = dinfo->bdrv;
if (bs) {
if (bs->private && match_fn(bs->private, arg)) {
drive_uninit(bs);
b... | {
"code": [],
"line_no": []
} | void FUNC_0(dev_match_fn *VAR_0, void *VAR_1)
{
DriveInfo *dinfo;
struct BlockDriverState *VAR_2;
TAILQ_FOREACH(dinfo, &drives, next) {
VAR_2 = dinfo->bdrv;
if (VAR_2) {
if (VAR_2->private && VAR_0(VAR_2->private, VAR_1)) {
drive_uninit(VAR_2);
... | [
"void FUNC_0(dev_match_fn *VAR_0, void *VAR_1)\n{",
"DriveInfo *dinfo;",
"struct BlockDriverState *VAR_2;",
"TAILQ_FOREACH(dinfo, &drives, next) {",
"VAR_2 = dinfo->bdrv;",
"if (VAR_2) {",
"if (VAR_2->private && VAR_0(VAR_2->private, VAR_1)) {",
"drive_uninit(VAR_2);",
"bdrv_delete(VAR_2);",
"}",
... | [
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
]
] |
4,631 | TranslationBlock *tb_gen_code(CPUState *cpu,
target_ulong pc, target_ulong cs_base,
int flags, int cflags)
{
CPUArchState *env = cpu->env_ptr;
TranslationBlock *tb;
tb_page_addr_t phys_pc, phys_page2;
target_ulong virt_page2;
tcg_in... | false | qemu | 56c0269a9ec105d3848d9f900b5e38e6b35e2478 | TranslationBlock *tb_gen_code(CPUState *cpu,
target_ulong pc, target_ulong cs_base,
int flags, int cflags)
{
CPUArchState *env = cpu->env_ptr;
TranslationBlock *tb;
tb_page_addr_t phys_pc, phys_page2;
target_ulong virt_page2;
tcg_in... | {
"code": [],
"line_no": []
} | TranslationBlock *FUNC_0(CPUState *cpu,
target_ulong pc, target_ulong cs_base,
int flags, int cflags)
{
CPUArchState *env = cpu->env_ptr;
TranslationBlock *tb;
tb_page_addr_t phys_pc, phys_page2;
target_ulong virt_page2;
tcg_insn_un... | [
"TranslationBlock *FUNC_0(CPUState *cpu,\ntarget_ulong pc, target_ulong cs_base,\nint flags, int cflags)\n{",
"CPUArchState *env = cpu->env_ptr;",
"TranslationBlock *tb;",
"tb_page_addr_t phys_pc, phys_page2;",
"target_ulong virt_page2;",
"tcg_insn_unit *gen_code_buf;",
"int VAR_0, VAR_1;",
"#ifdef CO... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
25,
29
],
[
31
],
[
33
],
[
35
],
[
39
],
[
41
],
[
43,
47
],
[
51
],
[
53
],
[... |
4,632 | static void virtio_blk_handle_write(VirtIOBlockReq *req, MultiReqBuffer *mrb)
{
BlockRequest *blkreq;
uint64_t sector;
sector = virtio_ldq_p(VIRTIO_DEVICE(req->dev), &req->out.sector);
trace_virtio_blk_handle_write(req, sector, req->qiov.size / 512);
if (!virtio_blk_sect_range_ok(req->de... | false | qemu | 4be746345f13e99e468c60acbd3a355e8183e3ce | static void virtio_blk_handle_write(VirtIOBlockReq *req, MultiReqBuffer *mrb)
{
BlockRequest *blkreq;
uint64_t sector;
sector = virtio_ldq_p(VIRTIO_DEVICE(req->dev), &req->out.sector);
trace_virtio_blk_handle_write(req, sector, req->qiov.size / 512);
if (!virtio_blk_sect_range_ok(req->de... | {
"code": [],
"line_no": []
} | static void FUNC_0(VirtIOBlockReq *VAR_0, MultiReqBuffer *VAR_1)
{
BlockRequest *blkreq;
uint64_t sector;
sector = virtio_ldq_p(VIRTIO_DEVICE(VAR_0->dev), &VAR_0->out.sector);
trace_virtio_blk_handle_write(VAR_0, sector, VAR_0->qiov.size / 512);
if (!virtio_blk_sect_range_ok(VAR_0->dev, ... | [
"static void FUNC_0(VirtIOBlockReq *VAR_0, MultiReqBuffer *VAR_1)\n{",
"BlockRequest *blkreq;",
"uint64_t sector;",
"sector = virtio_ldq_p(VIRTIO_DEVICE(VAR_0->dev), &VAR_0->out.sector);",
"trace_virtio_blk_handle_write(VAR_0, sector, VAR_0->qiov.size / 512);",
"if (!virtio_blk_sect_range_ok(VAR_0->dev, s... | [
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
],
[
15
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
31,
33
],
[
37
],
[
39
],
[
41
],
[
45
],
[
47
],
[
49
],
[
51
],
[
53
],
... |
4,633 | static int vc1_parse(AVCodecParserContext *s,
AVCodecContext *avctx,
const uint8_t **poutbuf, int *poutbuf_size,
const uint8_t *buf, int buf_size)
{
/* Here we do the searching for frame boundaries and headers at
* the same ... | false | FFmpeg | ff771f79b55a346b4163d814b58ee4c98114745e | static int vc1_parse(AVCodecParserContext *s,
AVCodecContext *avctx,
const uint8_t **poutbuf, int *poutbuf_size,
const uint8_t *buf, int buf_size)
{
VC1ParseContext *vpc = s->priv_data;
int pic_found = vpc->pc.frame... | {
"code": [],
"line_no": []
} | static int FUNC_0(AVCodecParserContext *VAR_0,
AVCodecContext *VAR_1,
const uint8_t **VAR_2, int *VAR_3,
const uint8_t *VAR_4, int VAR_5)
{
VC1ParseContext *vpc = VAR_0->priv_data;
int VAR_6 = vpc->pc.frame_start_fo... | [
"static int FUNC_0(AVCodecParserContext *VAR_0,\nAVCodecContext *VAR_1,\nconst uint8_t **VAR_2, int *VAR_3,\nconst uint8_t *VAR_4, int VAR_5)\n{",
"VC1ParseContext *vpc = VAR_0->priv_data;",
"int VAR_6 = vpc->pc.frame_start_found;",
"uint8_t *unesc_buffer = vpc->unesc_buffer;",
"size_t unesc_index = vpc->un... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
35
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49
],
[
51
],
[
53
],
[... |
4,634 | static void bdrv_co_complete(BlockAIOCBCoroutine *acb)
{
if (!acb->need_bh) {
acb->common.cb(acb->common.opaque, acb->req.error);
qemu_aio_unref(acb);
}
}
| false | qemu | 61007b316cd71ee7333ff7a0a749a8949527575f | static void bdrv_co_complete(BlockAIOCBCoroutine *acb)
{
if (!acb->need_bh) {
acb->common.cb(acb->common.opaque, acb->req.error);
qemu_aio_unref(acb);
}
}
| {
"code": [],
"line_no": []
} | static void FUNC_0(BlockAIOCBCoroutine *VAR_0)
{
if (!VAR_0->need_bh) {
VAR_0->common.cb(VAR_0->common.opaque, VAR_0->req.error);
qemu_aio_unref(VAR_0);
}
}
| [
"static void FUNC_0(BlockAIOCBCoroutine *VAR_0)\n{",
"if (!VAR_0->need_bh) {",
"VAR_0->common.cb(VAR_0->common.opaque, VAR_0->req.error);",
"qemu_aio_unref(VAR_0);",
"}",
"}"
] | [
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
]
] |
4,635 | QObject *qmp_output_get_qobject(QmpOutputVisitor *qov)
{
/* FIXME: we should require that a visit occurred, and that it is
* complete (no starts without a matching end) */
QObject *obj = qov->root;
if (obj) {
qobject_incref(obj);
} else {
obj = qnull();
}
return ob... | false | qemu | 56a6f02b8ce1fe41a2a9077593e46eca7d98267d | QObject *qmp_output_get_qobject(QmpOutputVisitor *qov)
{
QObject *obj = qov->root;
if (obj) {
qobject_incref(obj);
} else {
obj = qnull();
}
return obj;
}
| {
"code": [],
"line_no": []
} | QObject *FUNC_0(QmpOutputVisitor *qov)
{
QObject *obj = qov->root;
if (obj) {
qobject_incref(obj);
} else {
obj = qnull();
}
return obj;
}
| [
"QObject *FUNC_0(QmpOutputVisitor *qov)\n{",
"QObject *obj = qov->root;",
"if (obj) {",
"qobject_incref(obj);",
"} else {",
"obj = qnull();",
"}",
"return obj;",
"}"
] | [
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
]
] |
4,637 | eeprom_t *eeprom93xx_new(DeviceState *dev, uint16_t nwords)
{
/* Add a new EEPROM (with 16, 64 or 256 words). */
eeprom_t *eeprom;
uint8_t addrbits;
switch (nwords) {
case 16:
case 64:
addrbits = 6;
break;
case 128:
case 256:
... | false | qemu | 6fedcaa1c5419fa89c31fd34dabbd71861c615d2 | eeprom_t *eeprom93xx_new(DeviceState *dev, uint16_t nwords)
{
eeprom_t *eeprom;
uint8_t addrbits;
switch (nwords) {
case 16:
case 64:
addrbits = 6;
break;
case 128:
case 256:
addrbits = 8;
break;
def... | {
"code": [],
"line_no": []
} | eeprom_t *FUNC_0(DeviceState *dev, uint16_t nwords)
{
eeprom_t *eeprom;
uint8_t addrbits;
switch (nwords) {
case 16:
case 64:
addrbits = 6;
break;
case 128:
case 256:
addrbits = 8;
break;
default:
... | [
"eeprom_t *FUNC_0(DeviceState *dev, uint16_t nwords)\n{",
"eeprom_t *eeprom;",
"uint8_t addrbits;",
"switch (nwords) {",
"case 16:\ncase 64:\naddrbits = 6;",
"break;",
"case 128:\ncase 256:\naddrbits = 8;",
"break;",
"default:\nassert(!\"Unsupported EEPROM size, fallback to 64 words!\");",
"nwords... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
7
],
[
9
],
[
13
],
[
15,
17,
19
],
[
21
],
[
23,
25,
27
],
[
29
],
[
31,
33
],
[
35
],
[
37
],
[
39
],
[
43
],
[
45
],
[
47
],
[
51
],
[
53
],
... |
4,638 | static void cdrom_change_cb(void *opaque)
{
IDEState *s = opaque;
uint64_t nb_sectors;
/* XXX: send interrupt too */
bdrv_get_geometry(s->bs, &nb_sectors);
s->nb_sectors = nb_sectors;
}
| false | qemu | 9118e7f08f39001c92d595090b41305ef45c200a | static void cdrom_change_cb(void *opaque)
{
IDEState *s = opaque;
uint64_t nb_sectors;
bdrv_get_geometry(s->bs, &nb_sectors);
s->nb_sectors = nb_sectors;
}
| {
"code": [],
"line_no": []
} | static void FUNC_0(void *VAR_0)
{
IDEState *s = VAR_0;
uint64_t nb_sectors;
bdrv_get_geometry(s->bs, &nb_sectors);
s->nb_sectors = nb_sectors;
}
| [
"static void FUNC_0(void *VAR_0)\n{",
"IDEState *s = VAR_0;",
"uint64_t nb_sectors;",
"bdrv_get_geometry(s->bs, &nb_sectors);",
"s->nb_sectors = nb_sectors;",
"}"
] | [
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
13
],
[
15
],
[
17
]
] |
4,641 | void *qpci_legacy_iomap(QPCIDevice *dev, uint16_t addr)
{
return (void *)(uintptr_t)addr;
}
| true | qemu | b4ba67d9a702507793c2724e56f98e9b0f7be02b | void *qpci_legacy_iomap(QPCIDevice *dev, uint16_t addr)
{
return (void *)(uintptr_t)addr;
}
| {
"code": [
"void *qpci_legacy_iomap(QPCIDevice *dev, uint16_t addr)",
" return (void *)(uintptr_t)addr;"
],
"line_no": [
1,
5
]
} | void *FUNC_0(QPCIDevice *VAR_0, uint16_t VAR_1)
{
return (void *)(uintptr_t)VAR_1;
}
| [
"void *FUNC_0(QPCIDevice *VAR_0, uint16_t VAR_1)\n{",
"return (void *)(uintptr_t)VAR_1;",
"}"
] | [
1,
1,
0
] | [
[
1,
3
],
[
5
],
[
7
]
] |
4,642 | static void trace(TraceEventID event, uint64_t x1, uint64_t x2, uint64_t x3,
uint64_t x4, uint64_t x5, uint64_t x6)
{
TraceRecord *rec = &trace_buf[trace_idx];
if (!trace_list[event].state) {
return;
}
rec->event = event;
rec->timestamp_ns = get_clock();
re... | true | qemu | 0b5538c300a56c3cfb33022840fe0b4968147e7a | static void trace(TraceEventID event, uint64_t x1, uint64_t x2, uint64_t x3,
uint64_t x4, uint64_t x5, uint64_t x6)
{
TraceRecord *rec = &trace_buf[trace_idx];
if (!trace_list[event].state) {
return;
}
rec->event = event;
rec->timestamp_ns = get_clock();
re... | {
"code": [
" TraceRecord *rec = &trace_buf[trace_idx];",
" rec->event = event;",
" rec->timestamp_ns = get_clock();",
" rec->x1 = x1;",
" rec->x2 = x2;",
" rec->x3 = x3;",
" rec->x4 = x4;",
" rec->x5 = x5;",
" rec->x6 = x6;",
" if (++trace_idx == ... | static void FUNC_0(TraceEventID VAR_0, uint64_t VAR_1, uint64_t VAR_2, uint64_t VAR_3,
uint64_t VAR_4, uint64_t VAR_5, uint64_t VAR_6)
{
TraceRecord *rec = &trace_buf[trace_idx];
if (!trace_list[VAR_0].state) {
return;
}
rec->VAR_0 = VAR_0;
rec->timestamp_ns = g... | [
"static void FUNC_0(TraceEventID VAR_0, uint64_t VAR_1, uint64_t VAR_2, uint64_t VAR_3,\nuint64_t VAR_4, uint64_t VAR_5, uint64_t VAR_6)\n{",
"TraceRecord *rec = &trace_buf[trace_idx];",
"if (!trace_list[VAR_0].state) {",
"return;",
"}",
"rec->VAR_0 = VAR_0;",
"rec->timestamp_ns = get_clock();",
"rec-... | [
0,
1,
0,
0,
0,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
11
],
[
13
],
[
15
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
37
],
[
39
],
[
41
],
[
43
]
] |
4,643 | static void gen_intermediate_code_internal(CPULM32State *env,
TranslationBlock *tb, int search_pc)
{
struct DisasContext ctx, *dc = &ctx;
uint16_t *gen_opc_end;
uint32_t pc_start;
int j, lj;
uint32_t next_page_start;
int num_insns;
int max_insns;
qemu_log_try_set_file... | true | qemu | 632314c49ce20ee9c974f07544d9125fbbbfbe1b | static void gen_intermediate_code_internal(CPULM32State *env,
TranslationBlock *tb, int search_pc)
{
struct DisasContext ctx, *dc = &ctx;
uint16_t *gen_opc_end;
uint32_t pc_start;
int j, lj;
uint32_t next_page_start;
int num_insns;
int max_insns;
qemu_log_try_set_file... | {
"code": [
" qemu_log_try_set_file(stderr);",
" qemu_log_try_set_file(stderr);",
" qemu_log_try_set_file(stderr);",
" qemu_log_try_set_file(stderr);"
],
"line_no": [
23,
23,
23,
23
]
} | static void FUNC_0(CPULM32State *VAR_0,
TranslationBlock *VAR_1, int VAR_2)
{
struct DisasContext VAR_3, *VAR_4 = &VAR_3;
uint16_t *gen_opc_end;
uint32_t pc_start;
int VAR_5, VAR_6;
uint32_t next_page_start;
int VAR_7;
int VAR_8;
qemu_log_try_set_file(stderr);
... | [
"static void FUNC_0(CPULM32State *VAR_0,\nTranslationBlock *VAR_1, int VAR_2)\n{",
"struct DisasContext VAR_3, *VAR_4 = &VAR_3;",
"uint16_t *gen_opc_end;",
"uint32_t pc_start;",
"int VAR_5, VAR_6;",
"uint32_t next_page_start;",
"int VAR_7;",
"int VAR_8;",
"qemu_log_try_set_file(stderr);",
"pc_star... | [
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,
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
],
[
27
],
[
29
],
[
31
],
[
35
],
[
39
],
[
41
],
[
43
],
[
45
],
[
49
],
[
51
],
[... |
4,644 | void acpi_gpe_init(ACPIREGS *ar, uint8_t len)
{
ar->gpe.len = len;
ar->gpe.sts = g_malloc0(len / 2);
ar->gpe.en = g_malloc0(len / 2);
}
| true | qemu | d9a3b33d2c9f996537b7f1d0246dee2d0120cefb | void acpi_gpe_init(ACPIREGS *ar, uint8_t len)
{
ar->gpe.len = len;
ar->gpe.sts = g_malloc0(len / 2);
ar->gpe.en = g_malloc0(len / 2);
}
| {
"code": [
" ar->gpe.sts = g_malloc0(len / 2);",
" ar->gpe.en = g_malloc0(len / 2);"
],
"line_no": [
7,
9
]
} | void FUNC_0(ACPIREGS *VAR_0, uint8_t VAR_1)
{
VAR_0->gpe.VAR_1 = VAR_1;
VAR_0->gpe.sts = g_malloc0(VAR_1 / 2);
VAR_0->gpe.en = g_malloc0(VAR_1 / 2);
}
| [
"void FUNC_0(ACPIREGS *VAR_0, uint8_t VAR_1)\n{",
"VAR_0->gpe.VAR_1 = VAR_1;",
"VAR_0->gpe.sts = g_malloc0(VAR_1 / 2);",
"VAR_0->gpe.en = g_malloc0(VAR_1 / 2);",
"}"
] | [
0,
0,
1,
1,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
]
] |
4,646 | static void xtensa_cpu_initfn(Object *obj)
{
CPUState *cs = CPU(obj);
XtensaCPU *cpu = XTENSA_CPU(obj);
XtensaCPUClass *xcc = XTENSA_CPU_GET_CLASS(obj);
CPUXtensaState *env = &cpu->env;
static bool tcg_inited;
cs->env_ptr = env;
env->config = xcc->config;
cpu_exec_init(cs, &er... | true | qemu | ce5b1bbf624b977a55ff7f85bb3871682d03baff | static void xtensa_cpu_initfn(Object *obj)
{
CPUState *cs = CPU(obj);
XtensaCPU *cpu = XTENSA_CPU(obj);
XtensaCPUClass *xcc = XTENSA_CPU_GET_CLASS(obj);
CPUXtensaState *env = &cpu->env;
static bool tcg_inited;
cs->env_ptr = env;
env->config = xcc->config;
cpu_exec_init(cs, &er... | {
"code": [
" cpu_exec_init(cs, &error_abort);",
" cpu_exec_init(cs, &error_abort);",
" cpu_exec_init(cs, &error_abort);",
" cpu_exec_init(cs, &error_abort);",
" cpu_exec_init(cs, &error_abort);",
" cpu_exec_init(cs, &error_abort);",
" cpu_exec_init(cs, &error_abort);"... | static void FUNC_0(Object *VAR_0)
{
CPUState *cs = CPU(VAR_0);
XtensaCPU *cpu = XTENSA_CPU(VAR_0);
XtensaCPUClass *xcc = XTENSA_CPU_GET_CLASS(VAR_0);
CPUXtensaState *env = &cpu->env;
static bool VAR_1;
cs->env_ptr = env;
env->config = xcc->config;
cpu_exec_init(cs, &error_abor... | [
"static void FUNC_0(Object *VAR_0)\n{",
"CPUState *cs = CPU(VAR_0);",
"XtensaCPU *cpu = XTENSA_CPU(VAR_0);",
"XtensaCPUClass *xcc = XTENSA_CPU_GET_CLASS(VAR_0);",
"CPUXtensaState *env = &cpu->env;",
"static bool VAR_1;",
"cs->env_ptr = env;",
"env->config = xcc->config;",
"cpu_exec_init(cs, &error_a... | [
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
17
],
[
19
],
[
21
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
]
] |
4,648 | static void dp8393x_class_init(ObjectClass *klass, void *data)
{
DeviceClass *dc = DEVICE_CLASS(klass);
set_bit(DEVICE_CATEGORY_NETWORK, dc->categories);
dc->realize = dp8393x_realize;
dc->reset = dp8393x_reset;
dc->vmsd = &vmstate_dp8393x;
dc->props = dp8393x_properties;
} | true | qemu | f6351288b65130deb8102b17143f5d84f817a02a | static void dp8393x_class_init(ObjectClass *klass, void *data)
{
DeviceClass *dc = DEVICE_CLASS(klass);
set_bit(DEVICE_CATEGORY_NETWORK, dc->categories);
dc->realize = dp8393x_realize;
dc->reset = dp8393x_reset;
dc->vmsd = &vmstate_dp8393x;
dc->props = dp8393x_properties;
} | {
"code": [],
"line_no": []
} | static void FUNC_0(ObjectClass *VAR_0, void *VAR_1)
{
DeviceClass *dc = DEVICE_CLASS(VAR_0);
set_bit(DEVICE_CATEGORY_NETWORK, dc->categories);
dc->realize = dp8393x_realize;
dc->reset = dp8393x_reset;
dc->vmsd = &vmstate_dp8393x;
dc->props = dp8393x_properties;
} | [
"static void FUNC_0(ObjectClass *VAR_0, void *VAR_1)\n{",
"DeviceClass *dc = DEVICE_CLASS(VAR_0);",
"set_bit(DEVICE_CATEGORY_NETWORK, dc->categories);",
"dc->realize = dp8393x_realize;",
"dc->reset = dp8393x_reset;",
"dc->vmsd = &vmstate_dp8393x;",
"dc->props = dp8393x_properties;",
"}"
] | [
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
21
]
] |
4,649 | static int mjpeg_decode_sof0(MJpegDecodeContext *s,
UINT8 *buf, int buf_size)
{
int len, nb_components, i, width, height;
init_get_bits(&s->gb, buf, buf_size);
/* XXX: verify len field validity */
len = get_bits(&s->gb, 16);
/* only 8 bits/component accepted *... | true | FFmpeg | af289048d8f720743ed82a4e674cff01ab02a836 | static int mjpeg_decode_sof0(MJpegDecodeContext *s,
UINT8 *buf, int buf_size)
{
int len, nb_components, i, width, height;
init_get_bits(&s->gb, buf, buf_size);
len = get_bits(&s->gb, 16);
if (get_bits(&s->gb, 8) != 8)
return -1;
height = g... | {
"code": [
" if (len != 8+(3*nb_components))"
],
"line_no": [
141
]
} | static int FUNC_0(MJpegDecodeContext *VAR_0,
UINT8 *VAR_1, int VAR_2)
{
int VAR_3, VAR_4, VAR_5, VAR_6, VAR_7;
init_get_bits(&VAR_0->gb, VAR_1, VAR_2);
VAR_3 = get_bits(&VAR_0->gb, 16);
if (get_bits(&VAR_0->gb, 8) != 8)
return -1;
VAR_7 = ... | [
"static int FUNC_0(MJpegDecodeContext *VAR_0,\nUINT8 *VAR_1, int VAR_2)\n{",
"int VAR_3, VAR_4, VAR_5, VAR_6, VAR_7;",
"init_get_bits(&VAR_0->gb, VAR_1, VAR_2);",
"VAR_3 = get_bits(&VAR_0->gb, 16);",
"if (get_bits(&VAR_0->gb, 8) != 8)\nreturn -1;",
"VAR_7 = get_bits(&VAR_0->gb, 16);",
"VAR_6 = get_bits(... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
] | [
[
1,
3,
5
],
[
7
],
[
11
],
[
17
],
[
21,
23
],
[
25
],
[
27
],
[
31
],
[
33,
35,
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[
49
],
[
51
],
[
53
],
[
57,
59
],
... |
4,651 | int ff_avfilter_graph_config_formats(AVFilterGraph *graph, AVClass *log_ctx)
{
int ret;
/* find supported formats from sub-filters, and merge along links */
if ((ret = query_formats(graph, log_ctx)) < 0)
return ret;
/* Once everything is merged, it's possible that we'll still have
... | false | FFmpeg | 63736fe48c30c5db313c3a25d1462ad31b2a1671 | int ff_avfilter_graph_config_formats(AVFilterGraph *graph, AVClass *log_ctx)
{
int ret;
if ((ret = query_formats(graph, log_ctx)) < 0)
return ret;
pick_formats(graph);
return 0;
}
| {
"code": [],
"line_no": []
} | int FUNC_0(AVFilterGraph *VAR_0, AVClass *VAR_1)
{
int VAR_2;
if ((VAR_2 = query_formats(VAR_0, VAR_1)) < 0)
return VAR_2;
pick_formats(VAR_0);
return 0;
}
| [
"int FUNC_0(AVFilterGraph *VAR_0, AVClass *VAR_1)\n{",
"int VAR_2;",
"if ((VAR_2 = query_formats(VAR_0, VAR_1)) < 0)\nreturn VAR_2;",
"pick_formats(VAR_0);",
"return 0;",
"}"
] | [
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
11,
13
],
[
21
],
[
25
],
[
27
]
] |
4,652 | static void avc_luma_midh_qrt_8w_msa(const uint8_t *src, int32_t src_stride,
uint8_t *dst, int32_t dst_stride,
int32_t height, uint8_t horiz_offset)
{
uint32_t multiple8_cnt;
for (multiple8_cnt = 2; multiple8_cnt--;) {
avc... | false | FFmpeg | e549933a270dd2cfc36f2cf9bb6b29acf3dc6d08 | static void avc_luma_midh_qrt_8w_msa(const uint8_t *src, int32_t src_stride,
uint8_t *dst, int32_t dst_stride,
int32_t height, uint8_t horiz_offset)
{
uint32_t multiple8_cnt;
for (multiple8_cnt = 2; multiple8_cnt--;) {
avc... | {
"code": [],
"line_no": []
} | static void FUNC_0(const uint8_t *VAR_0, int32_t VAR_1,
uint8_t *VAR_2, int32_t VAR_3,
int32_t VAR_4, uint8_t VAR_5)
{
uint32_t multiple8_cnt;
for (multiple8_cnt = 2; multiple8_cnt--;) {
avc_luma_midh_qrt_4w_msa(VAR_0, VAR... | [
"static void FUNC_0(const uint8_t *VAR_0, int32_t VAR_1,\nuint8_t *VAR_2, int32_t VAR_3,\nint32_t VAR_4, uint8_t VAR_5)\n{",
"uint32_t multiple8_cnt;",
"for (multiple8_cnt = 2; multiple8_cnt--;) {",
"avc_luma_midh_qrt_4w_msa(VAR_0, VAR_1, VAR_2, VAR_3, VAR_4,\nVAR_5);",
"VAR_0 += 4;",
"VAR_2 += 4;",
"}"... | [
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5,
7
],
[
9
],
[
13
],
[
15,
17
],
[
21
],
[
23
],
[
25
],
[
27
]
] |
4,653 | target_ulong helper_msub32_suov(CPUTriCoreState *env, target_ulong r1,
target_ulong r2, target_ulong r3)
{
int64_t t1 = extract64(r1, 0, 32);
int64_t t2 = extract64(r2, 0, 32);
int64_t t3 = extract64(r3, 0, 32);
int64_t result;
result = t2 - (t1 * t3);
r... | true | qemu | 3debbb5af5f63440b170b71bf3aecc0e778f5691 | target_ulong helper_msub32_suov(CPUTriCoreState *env, target_ulong r1,
target_ulong r2, target_ulong r3)
{
int64_t t1 = extract64(r1, 0, 32);
int64_t t2 = extract64(r2, 0, 32);
int64_t t3 = extract64(r3, 0, 32);
int64_t result;
result = t2 - (t1 * t3);
r... | {
"code": [
" int64_t t1 = extract64(r1, 0, 32);",
" int64_t t2 = extract64(r2, 0, 32);",
" int64_t t3 = extract64(r3, 0, 32);",
" int64_t result;",
" result = t2 - (t1 * t3);",
" return suov32_neg(env, result);"
],
"line_no": [
7,
9,
11,
13,
17,
1... | target_ulong FUNC_0(CPUTriCoreState *env, target_ulong r1,
target_ulong r2, target_ulong r3)
{
int64_t t1 = extract64(r1, 0, 32);
int64_t t2 = extract64(r2, 0, 32);
int64_t t3 = extract64(r3, 0, 32);
int64_t result;
result = t2 - (t1 * t3);
return suov32... | [
"target_ulong FUNC_0(CPUTriCoreState *env, target_ulong r1,\ntarget_ulong r2, target_ulong r3)\n{",
"int64_t t1 = extract64(r1, 0, 32);",
"int64_t t2 = extract64(r2, 0, 32);",
"int64_t t3 = extract64(r3, 0, 32);",
"int64_t result;",
"result = t2 - (t1 * t3);",
"return suov32_neg(env, result);",
"}"
] | [
0,
1,
1,
1,
1,
1,
1,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
17
],
[
19
],
[
21
]
] |
4,655 | static CharDriverState *qemu_chr_open_fd(int fd_in, int fd_out)
{
CharDriverState *chr;
FDCharDriver *s;
chr = qemu_chr_alloc();
s = g_malloc0(sizeof(FDCharDriver));
s->fd_in = io_channel_from_fd(fd_in);
s->fd_out = io_channel_from_fd(fd_out);
qemu_set_nonblock(fd_out);
s->chr... | true | qemu | 2d528d45ecf5ee3c1a566a9f3d664464925ef830 | static CharDriverState *qemu_chr_open_fd(int fd_in, int fd_out)
{
CharDriverState *chr;
FDCharDriver *s;
chr = qemu_chr_alloc();
s = g_malloc0(sizeof(FDCharDriver));
s->fd_in = io_channel_from_fd(fd_in);
s->fd_out = io_channel_from_fd(fd_out);
qemu_set_nonblock(fd_out);
s->chr... | {
"code": [
" s = g_malloc0(sizeof(FDCharDriver));"
],
"line_no": [
13
]
} | static CharDriverState *FUNC_0(int fd_in, int fd_out)
{
CharDriverState *chr;
FDCharDriver *s;
chr = qemu_chr_alloc();
s = g_malloc0(sizeof(FDCharDriver));
s->fd_in = io_channel_from_fd(fd_in);
s->fd_out = io_channel_from_fd(fd_out);
qemu_set_nonblock(fd_out);
s->chr = chr;
... | [
"static CharDriverState *FUNC_0(int fd_in, int fd_out)\n{",
"CharDriverState *chr;",
"FDCharDriver *s;",
"chr = qemu_chr_alloc();",
"s = g_malloc0(sizeof(FDCharDriver));",
"s->fd_in = io_channel_from_fd(fd_in);",
"s->fd_out = io_channel_from_fd(fd_out);",
"qemu_set_nonblock(fd_out);",
"s->chr = chr;... | [
0,
0,
0,
0,
1,
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
],
[
35
],
[
37
]
] |
4,656 | static void mpeg_er_decode_mb(void *opaque, int ref, int mv_dir, int mv_type,
int (*mv)[2][4][2], int mb_x, int mb_y,
int mb_intra, int mb_skipped)
{
MpegEncContext *s = opaque;
s->mv_dir = mv_dir;
s->mv_type = mv_type;
s->mb_in... | true | FFmpeg | 127a362630e11fe724e2e63fc871791fdcbcfa64 | static void mpeg_er_decode_mb(void *opaque, int ref, int mv_dir, int mv_type,
int (*mv)[2][4][2], int mb_x, int mb_y,
int mb_intra, int mb_skipped)
{
MpegEncContext *s = opaque;
s->mv_dir = mv_dir;
s->mv_type = mv_type;
s->mb_in... | {
"code": [],
"line_no": []
} | static void FUNC_0(void *VAR_0, int VAR_1, int VAR_2, int VAR_3,
int (*VAR_4)[2][4][2], int VAR_5, int VAR_6,
int VAR_7, int VAR_8)
{
MpegEncContext *s = VAR_0;
s->VAR_2 = VAR_2;
s->VAR_3 = VAR_3;
s->VAR_7 = VAR_7;
s->VAR... | [
"static void FUNC_0(void *VAR_0, int VAR_1, int VAR_2, int VAR_3,\nint (*VAR_4)[2][4][2], int VAR_5, int VAR_6,\nint VAR_7, int VAR_8)\n{",
"MpegEncContext *s = VAR_0;",
"s->VAR_2 = VAR_2;",
"s->VAR_3 = VAR_3;",
"s->VAR_7 = VAR_7;",
"s->VAR_8 = VAR_8;",
"s->VAR_5 = VAR_5;",
"s->VAR_6 ... | [
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
],
[
26
],
[
30
],
[
32
],
[
36
],
[
40,
42,
44
],
[
46,
48,
50
],
[
52,
54,
56
],
[
60,... |
4,657 | static int field_end(H264Context *h, int in_setup)
{
MpegEncContext *const s = &h->s;
AVCodecContext *const avctx = s->avctx;
int err = 0;
s->mb_y = 0;
if (!in_setup && !s->dropable)
ff_thread_report_progress(&s->current_picture_ptr->f,
(16 * s... | true | FFmpeg | 1e26a48fa23ef8e1cbc424667d387184d8155f15 | static int field_end(H264Context *h, int in_setup)
{
MpegEncContext *const s = &h->s;
AVCodecContext *const avctx = s->avctx;
int err = 0;
s->mb_y = 0;
if (!in_setup && !s->dropable)
ff_thread_report_progress(&s->current_picture_ptr->f,
(16 * s... | {
"code": [
" ff_thread_report_progress(&s->current_picture_ptr->f,",
" (16 * s->mb_height >> FIELD_PICTURE) - 1,"
],
"line_no": [
17,
19
]
} | static int FUNC_0(H264Context *VAR_0, int VAR_1)
{
MpegEncContext *const s = &VAR_0->s;
AVCodecContext *const avctx = s->avctx;
int VAR_2 = 0;
s->mb_y = 0;
if (!VAR_1 && !s->dropable)
ff_thread_report_progress(&s->current_picture_ptr->f,
(16 * ... | [
"static int FUNC_0(H264Context *VAR_0, int VAR_1)\n{",
"MpegEncContext *const s = &VAR_0->s;",
"AVCodecContext *const avctx = s->avctx;",
"int VAR_2 = 0;",
"s->mb_y = 0;",
"if (!VAR_1 && !s->dropable)\nff_thread_report_progress(&s->current_picture_ptr->f,\n(16 * s->mb_height >> FIELD_PICTURE) - 1,\ns-... | [
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
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
15,
17,
19,
21
],
[
25,
27,
29
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49
],
[
51
],
[... |
4,658 | static void coroutine_fn backup_run(void *opaque)
{
BackupBlockJob *job = opaque;
BackupCompleteData *data;
BlockDriverState *bs = job->common.bs;
BlockDriverState *target = job->target;
BlockdevOnError on_target_error = job->on_target_error;
NotifierWithReturn before_write = {
.... | true | qemu | c29c1dd312f39ec18a3c6177c6da09a75e095d70 | static void coroutine_fn backup_run(void *opaque)
{
BackupBlockJob *job = opaque;
BackupCompleteData *data;
BlockDriverState *bs = job->common.bs;
BlockDriverState *target = job->target;
BlockdevOnError on_target_error = job->on_target_error;
NotifierWithReturn before_write = {
.... | {
"code": [],
"line_no": []
} | static void VAR_0 backup_run(void *opaque)
{
BackupBlockJob *job = opaque;
BackupCompleteData *data;
BlockDriverState *bs = job->common.bs;
BlockDriverState *target = job->target;
BlockdevOnError on_target_error = job->on_target_error;
NotifierWithReturn before_write = {
.notify ... | [
"static void VAR_0 backup_run(void *opaque)\n{",
"BackupBlockJob *job = opaque;",
"BackupCompleteData *data;",
"BlockDriverState *bs = job->common.bs;",
"BlockDriverState *target = job->target;",
"BlockdevOnError on_target_error = job->on_target_error;",
"NotifierWithReturn before_write = {",
".notify... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
33
],
[
35,
37
],
[
41
],
[
45
],
[
47
],
[
49
],
[
53
... |
4,659 | static void force_sigsegv(int oldsig)
{
CPUState *cpu = thread_cpu;
CPUArchState *env = cpu->env_ptr;
target_siginfo_t info;
if (oldsig == SIGSEGV) {
/* Make sure we don't try to deliver the signal again; this will
* end up with handle_pending_signal() calling force_sig().
... | true | qemu | c599d4d6d6e9bfdb64e54c33a22cb26e3496b96d | static void force_sigsegv(int oldsig)
{
CPUState *cpu = thread_cpu;
CPUArchState *env = cpu->env_ptr;
target_siginfo_t info;
if (oldsig == SIGSEGV) {
sigact_table[oldsig - 1]._sa_handler = TARGET_SIG_DFL;
}
info.si_signo = TARGET_SIGSEGV;
info.si_errno = 0;
... | {
"code": [],
"line_no": []
} | static void FUNC_0(int VAR_0)
{
CPUState *cpu = thread_cpu;
CPUArchState *env = cpu->env_ptr;
target_siginfo_t info;
if (VAR_0 == SIGSEGV) {
sigact_table[VAR_0 - 1]._sa_handler = TARGET_SIG_DFL;
}
info.si_signo = TARGET_SIGSEGV;
info.si_errno = 0;
info.s... | [
"static void FUNC_0(int VAR_0)\n{",
"CPUState *cpu = thread_cpu;",
"CPUArchState *env = cpu->env_ptr;",
"target_siginfo_t info;",
"if (VAR_0 == SIGSEGV) {",
"sigact_table[VAR_0 - 1]._sa_handler = TARGET_SIG_DFL;",
"}",
"info.si_signo = TARGET_SIGSEGV;",
"info.si_errno = 0;",
"info.si_code = TARGET... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
13
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
]
] |
4,660 | static void vnc_update_client(void *opaque)
{
VncState *vs = opaque;
if (vs->need_update && vs->csock != -1) {
int y;
uint8_t *row;
char *old_row;
uint32_t width_mask[VNC_DIRTY_WORDS];
int n_rectangles;
int saved_offset;
int has_dirty = 0;
... | true | qemu | 6baebed7698a37a0ac5168faf26023426b0ac940 | static void vnc_update_client(void *opaque)
{
VncState *vs = opaque;
if (vs->need_update && vs->csock != -1) {
int y;
uint8_t *row;
char *old_row;
uint32_t width_mask[VNC_DIRTY_WORDS];
int n_rectangles;
int saved_offset;
int has_dirty = 0;
... | {
"code": [
" uint8_t *row;",
" char *old_row;",
" row = ds_get_data(vs->ds);",
" old_row = vs->old_data;",
" for (y = 0; y < ds_get_height(vs->ds); y++) {",
" if (vnc_and_bits(vs->dirty_row[y], width_mask, VNC_DIRTY_WORDS)) {",
" ... | static void FUNC_0(void *VAR_0)
{
VncState *vs = VAR_0;
if (vs->need_update && vs->csock != -1) {
int VAR_1;
uint8_t *row;
char *VAR_2;
uint32_t width_mask[VNC_DIRTY_WORDS];
int VAR_3;
int VAR_4;
int VAR_5 = 0;
vga_hw_update();
... | [
"static void FUNC_0(void *VAR_0)\n{",
"VncState *vs = VAR_0;",
"if (vs->need_update && vs->csock != -1) {",
"int VAR_1;",
"uint8_t *row;",
"char *VAR_2;",
"uint32_t width_mask[VNC_DIRTY_WORDS];",
"int VAR_3;",
"int VAR_4;",
"int VAR_5 = 0;",
"vga_hw_update();",
"vnc_set_bits(width_mask, (ds_ge... | [
0,
0,
0,
0,
1,
1,
0,
0,
0,
0,
0,
0,
1,
1,
1,
1,
0,
1,
1,
1,
1,
1,
1,
1,
0,
1,
1,
0,
1,
1,
0,
0,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
1,
1,
0,
0,
0,
1,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
1... | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
25
],
[
29
],
[
37
],
[
39
],
[
43
],
[
45
],
[
47
],
[
49
],
[
51
],
[
55
... |
4,661 | static int video_open(VideoState *is)
{
int w,h;
if (screen_width) {
w = screen_width;
h = screen_height;
} else {
w = default_width;
h = default_height;
}
if (!window) {
int flags = SDL_WINDOW_SHOWN | SDL_WINDOW_RESIZABLE;
if (!window_... | true | FFmpeg | 15d7e31dcb68f30ebd725c495a191d5917a3b602 | static int video_open(VideoState *is)
{
int w,h;
if (screen_width) {
w = screen_width;
h = screen_height;
} else {
w = default_width;
h = default_height;
}
if (!window) {
int flags = SDL_WINDOW_SHOWN | SDL_WINDOW_RESIZABLE;
if (!window_... | {
"code": [],
"line_no": []
} | static int FUNC_0(VideoState *VAR_0)
{
int VAR_1,VAR_2;
if (screen_width) {
VAR_1 = screen_width;
VAR_2 = screen_height;
} else {
VAR_1 = default_width;
VAR_2 = default_height;
}
if (!window) {
int VAR_3 = SDL_WINDOW_SHOWN | SDL_WINDOW_RESIZABLE... | [
"static int FUNC_0(VideoState *VAR_0)\n{",
"int VAR_1,VAR_2;",
"if (screen_width) {",
"VAR_1 = screen_width;",
"VAR_2 = screen_height;",
"} else {",
"VAR_1 = default_width;",
"VAR_2 = default_height;",
"}",
"if (!window) {",
"int VAR_3 = SDL_WINDOW_SHOWN | SDL_WINDOW_RESIZABLE;",
"if (!window_... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
21
],
[
25
],
[
27
],
[
29,
31
],
[
33,
35
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49... |
4,662 | static void FUNCC(pred4x4_129_dc)(uint8_t *_src, const uint8_t *topright, int _stride){
pixel *src = (pixel*)_src;
int stride = _stride/sizeof(pixel);
((pixel4*)(src+0*stride))[0]=
((pixel4*)(src+1*stride))[0]=
((pixel4*)(src+2*stride))[0]=
((pixel4*)(src+3*stride))[0]= PIXEL_SPLAT_X4((1<<... | true | FFmpeg | 2caf19e90f270abe1e80a3e85acaf0eb5c9d0aac | static void FUNCC(pred4x4_129_dc)(uint8_t *_src, const uint8_t *topright, int _stride){
pixel *src = (pixel*)_src;
int stride = _stride/sizeof(pixel);
((pixel4*)(src+0*stride))[0]=
((pixel4*)(src+1*stride))[0]=
((pixel4*)(src+2*stride))[0]=
((pixel4*)(src+3*stride))[0]= PIXEL_SPLAT_X4((1<<... | {
"code": [
" ((pixel4*)(src+0*stride))[0]=",
" ((pixel4*)(src+1*stride))[0]=",
" ((pixel4*)(src+2*stride))[0]=",
" ((pixel4*)(src+0*stride))[0]=",
" ((pixel4*)(src+1*stride))[0]=",
" ((pixel4*)(src+2*stride))[0]=",
" ((pixel4*)(src+0*stride))[0]=",
" ((pixel4*)... | static void FUNC_0(pred4x4_129_dc)(uint8_t *_src, const uint8_t *topright, int _stride){
pixel *src = (pixel*)_src;
int VAR_0 = _stride/sizeof(pixel);
((pixel4*)(src+0*VAR_0))[0]=
((pixel4*)(src+1*VAR_0))[0]=
((pixel4*)(src+2*VAR_0))[0]=
((pixel4*)(src+3*VAR_0))[0]= PIXEL_SPLAT_X4((1<<(BIT... | [
"static void FUNC_0(pred4x4_129_dc)(uint8_t *_src, const uint8_t *topright, int _stride){",
"pixel *src = (pixel*)_src;",
"int VAR_0 = _stride/sizeof(pixel);",
"((pixel4*)(src+0*VAR_0))[0]=\n((pixel4*)(src+1*VAR_0))[0]=\n((pixel4*)(src+2*VAR_0))[0]=\n((pixel4*)(src+3*VAR_0))[0]= PIXEL_SPLAT_X4((1<<(BIT_DEPTH-... | [
0,
0,
0,
1,
0
] | [
[
1
],
[
3
],
[
5
],
[
7,
9,
11,
13
],
[
15
]
] |
4,663 | static int ehci_reset_queue(EHCIQueue *q)
{
int packets;
trace_usb_ehci_queue_action(q, "reset");
packets = ehci_cancel_queue(q);
q->dev = NULL;
q->qtdaddr = 0;
return packets;
} | true | qemu | bbbc39ccacf66ef58261c155f9eed503947c3023 | static int ehci_reset_queue(EHCIQueue *q)
{
int packets;
trace_usb_ehci_queue_action(q, "reset");
packets = ehci_cancel_queue(q);
q->dev = NULL;
q->qtdaddr = 0;
return packets;
} | {
"code": [],
"line_no": []
} | static int FUNC_0(EHCIQueue *VAR_0)
{
int VAR_1;
trace_usb_ehci_queue_action(VAR_0, "reset");
VAR_1 = ehci_cancel_queue(VAR_0);
VAR_0->dev = NULL;
VAR_0->qtdaddr = 0;
return VAR_1;
} | [
"static int FUNC_0(EHCIQueue *VAR_0)\n{",
"int VAR_1;",
"trace_usb_ehci_queue_action(VAR_0, \"reset\");",
"VAR_1 = ehci_cancel_queue(VAR_0);",
"VAR_0->dev = NULL;",
"VAR_0->qtdaddr = 0;",
"return VAR_1;",
"}"
] | [
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
],
[
13
],
[
15
],
[
18
],
[
20
]
] |
4,664 | static void fill_caches(H264Context *h, int mb_type, int for_deblock){
MpegEncContext * const s = &h->s;
const int mb_xy= h->mb_xy;
int topleft_xy, top_xy, topright_xy, left_xy[2];
int topleft_type, top_type, topright_type, left_type[2];
int * left_block;
int topleft_partition= -1;
in... | true | FFmpeg | 0281d32550639c806b7eccd2b17cc5d125e4253d | static void fill_caches(H264Context *h, int mb_type, int for_deblock){
MpegEncContext * const s = &h->s;
const int mb_xy= h->mb_xy;
int topleft_xy, top_xy, topright_xy, left_xy[2];
int topleft_type, top_type, topright_type, left_type[2];
int * left_block;
int topleft_partition= -1;
in... | {
"code": [
" if((for_deblock || (IS_DIRECT(mb_type) && !h->direct_spatial_mv_pred)) && !FRAME_MBAFF)"
],
"line_no": [
581
]
} | static void FUNC_0(H264Context *VAR_0, int VAR_1, int VAR_2){
MpegEncContext * const s = &VAR_0->s;
const int VAR_3= VAR_0->VAR_3;
int VAR_4, VAR_5, VAR_6, VAR_7[2];
int VAR_8, VAR_9, VAR_10, VAR_11[2];
int * VAR_12;
int VAR_13= -1;
int VAR_14;
VAR_5 = VAR_3 - (s->mb_strid... | [
"static void FUNC_0(H264Context *VAR_0, int VAR_1, int VAR_2){",
"MpegEncContext * const s = &VAR_0->s;",
"const int VAR_3= VAR_0->VAR_3;",
"int VAR_4, VAR_5, VAR_6, VAR_7[2];",
"int VAR_8, VAR_9, VAR_10, VAR_11[2];",
"int * VAR_12;",
"int VAR_13= -1;",
"int VAR_14;",
"VAR_5 = VAR_3 - (s->mb_st... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49
],
[
51
],
[
53
],
[
55
... |
4,666 | static void lsi_scsi_init(PCIDevice *dev)
{
LSIState *s = (LSIState *)dev;
uint8_t *pci_conf;
pci_conf = s->pci_dev.config;
/* PCI Vendor ID (word) */
pci_config_set_vendor_id(pci_conf, PCI_VENDOR_ID_LSI_LOGIC);
/* PCI device ID (word) */
pci_config_set_device_id(pci_conf, PCI_DEVICE_ID_LSI_... | true | qemu | 777aec7ac91b1306d77897aafc8097a87bf4a672 | static void lsi_scsi_init(PCIDevice *dev)
{
LSIState *s = (LSIState *)dev;
uint8_t *pci_conf;
pci_conf = s->pci_dev.config;
pci_config_set_vendor_id(pci_conf, PCI_VENDOR_ID_LSI_LOGIC);
pci_config_set_device_id(pci_conf, PCI_DEVICE_ID_LSI_53C895A);
pci_config_set_class(pci_conf, PC... | {
"code": [],
"line_no": []
} | static void FUNC_0(PCIDevice *VAR_0)
{
LSIState *s = (LSIState *)VAR_0;
uint8_t *pci_conf;
pci_conf = s->pci_dev.config;
pci_config_set_vendor_id(pci_conf, PCI_VENDOR_ID_LSI_LOGIC);
pci_config_set_device_id(pci_conf, PCI_DEVICE_ID_LSI_53C895A);
pci_config_set_class(pci_conf, PCI_C... | [
"static void FUNC_0(PCIDevice *VAR_0)\n{",
"LSIState *s = (LSIState *)VAR_0;",
"uint8_t *pci_conf;",
"pci_conf = s->pci_dev.config;",
"pci_config_set_vendor_id(pci_conf, PCI_VENDOR_ID_LSI_LOGIC);",
"pci_config_set_device_id(pci_conf, PCI_DEVICE_ID_LSI_53C895A);",
"pci_config_set_class(pci_conf, PCI_CLAS... | [
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
],
[
7
],
[
9
],
[
11
],
[
13
],
[
14
],
[
16
],
[
18
],
[
19,
20
],
[
21,
22
],
[
23,
24
],
[
25,
26
],
[
27,
28
],
[
29
],
[
... |
4,667 | int ff_j2k_init_component(J2kComponent *comp, J2kCodingStyle *codsty, J2kQuantStyle *qntsty, int cbps, int dx, int dy)
{
int reslevelno, bandno, gbandno = 0, ret, i, j, csize = 1;
if (ret=ff_j2k_dwt_init(&comp->dwt, comp->coord, codsty->nreslevels-1, codsty->transform))
return ret;
for (i = 0... | true | FFmpeg | 45ae9a8fc903d5b5041a5d34015aa98ab2bc12be | int ff_j2k_init_component(J2kComponent *comp, J2kCodingStyle *codsty, J2kQuantStyle *qntsty, int cbps, int dx, int dy)
{
int reslevelno, bandno, gbandno = 0, ret, i, j, csize = 1;
if (ret=ff_j2k_dwt_init(&comp->dwt, comp->coord, codsty->nreslevels-1, codsty->transform))
return ret;
for (i = 0... | {
"code": [
" band->cblk = av_malloc(band->cblknx * band->cblkny * sizeof(J2kCblk));"
],
"line_no": [
173
]
} | int FUNC_0(J2kComponent *VAR_0, J2kCodingStyle *VAR_1, J2kQuantStyle *VAR_2, int VAR_3, int VAR_4, int VAR_5)
{
int VAR_6, VAR_7, VAR_8 = 0, VAR_9, VAR_10, VAR_11, VAR_12 = 1;
if (VAR_9=ff_j2k_dwt_init(&VAR_0->dwt, VAR_0->coord, VAR_1->nreslevels-1, VAR_1->transform))
return VAR_9;
for (VAR_1... | [
"int FUNC_0(J2kComponent *VAR_0, J2kCodingStyle *VAR_1, J2kQuantStyle *VAR_2, int VAR_3, int VAR_4, int VAR_5)\n{",
"int VAR_6, VAR_7, VAR_8 = 0, VAR_9, VAR_10, VAR_11, VAR_12 = 1;",
"if (VAR_9=ff_j2k_dwt_init(&VAR_0->dwt, VAR_0->coord, VAR_1->nreslevels-1, VAR_1->transform))\nreturn VAR_9;",
"for (VAR_10 = 0... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
9,
11
],
[
13
],
[
15
],
[
19
],
[
21,
23
],
[
25
],
[
29,
31
],
[
33
],
[
35
],
[
37
],
[
41
],
[
43
],
[
45,
47
],
[
51,
53
],
[
55,
57... |
4,669 | void vncws_tls_handshake_io(void *opaque)
{
VncState *vs = (VncState *)opaque;
if (!vs->tls.session) {
VNC_DEBUG("TLS Websocket setup\n");
if (vnc_tls_client_setup(vs, vs->vd->tls.x509cert != NULL) < 0) {
return;
}
}
VNC_DEBUG("Handshake IO continue\n");
... | true | qemu | 3e305e4a4752f70c0b5c3cf5b43ec957881714f7 | void vncws_tls_handshake_io(void *opaque)
{
VncState *vs = (VncState *)opaque;
if (!vs->tls.session) {
VNC_DEBUG("TLS Websocket setup\n");
if (vnc_tls_client_setup(vs, vs->vd->tls.x509cert != NULL) < 0) {
return;
}
}
VNC_DEBUG("Handshake IO continue\n");
... | {
"code": [
" if (!vs->tls.session) {",
" VNC_DEBUG(\"TLS Websocket setup\\n\");",
" if (vnc_tls_client_setup(vs, vs->vd->tls.x509cert != NULL) < 0) {",
" VNC_DEBUG(\"Handshake IO continue\\n\");"
],
"line_no": [
9,
11,
13,
21
]
} | void FUNC_0(void *VAR_0)
{
VncState *vs = (VncState *)VAR_0;
if (!vs->tls.session) {
VNC_DEBUG("TLS Websocket setup\n");
if (vnc_tls_client_setup(vs, vs->vd->tls.x509cert != NULL) < 0) {
return;
}
}
VNC_DEBUG("Handshake IO continue\n");
vncws_start_tls... | [
"void FUNC_0(void *VAR_0)\n{",
"VncState *vs = (VncState *)VAR_0;",
"if (!vs->tls.session) {",
"VNC_DEBUG(\"TLS Websocket setup\\n\");",
"if (vnc_tls_client_setup(vs, vs->vd->tls.x509cert != NULL) < 0) {",
"return;",
"}",
"}",
"VNC_DEBUG(\"Handshake IO continue\\n\");",
"vncws_start_tls_handshake(... | [
0,
0,
1,
1,
1,
0,
0,
0,
1,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
]
] |
4,670 | int css_do_rsch(SubchDev *sch)
{
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 = -EINPROGRE... | true | qemu | 66dc50f7057b9a0191f54e55764412202306858d | int css_do_rsch(SubchDev *sch)
{
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 = -EINPROGRE... | {
"code": [
" int ret;",
" ret = -ENODEV;",
" return ret;",
" return ret;",
" int ret;",
" ret = -ENODEV;",
" goto out;",
" ret = -EINPROGRESS;",
" goto out;",
" goto out;",
"out:",
" return ret;",
"int css_do... | int FUNC_0(SubchDev *VAR_0)
{
SCSW *s = &VAR_0->curr_status.scsw;
PMCW *p = &VAR_0->curr_status.pmcw;
int VAR_1;
if (~(p->flags) & (PMCW_FLAGS_MASK_DNV | PMCW_FLAGS_MASK_ENA)) {
VAR_1 = -ENODEV;
goto out;
}
if (s->ctrl & SCSW_STCTL_STATUS_PEND) {
VAR_1 = -EI... | [
"int FUNC_0(SubchDev *VAR_0)\n{",
"SCSW *s = &VAR_0->curr_status.scsw;",
"PMCW *p = &VAR_0->curr_status.pmcw;",
"int VAR_1;",
"if (~(p->flags) & (PMCW_FLAGS_MASK_DNV | PMCW_FLAGS_MASK_ENA)) {",
"VAR_1 = -ENODEV;",
"goto out;",
"}",
"if (s->ctrl & SCSW_STCTL_STATUS_PEND) {",
"VAR_1 = -EINPROGRESS;"... | [
1,
0,
0,
1,
0,
1,
1,
0,
0,
1,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
1,
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
... |
4,671 | ram_addr_t ppc4xx_sdram_adjust(ram_addr_t ram_size, int nr_banks,
MemoryRegion ram_memories[],
hwaddr ram_bases[],
hwaddr ram_sizes[],
const unsigned int sdram_bank_sizes[])
{
ram_addr_t... | true | qemu | e206ad48333c50373663945746828fc893b50700 | ram_addr_t ppc4xx_sdram_adjust(ram_addr_t ram_size, int nr_banks,
MemoryRegion ram_memories[],
hwaddr ram_bases[],
hwaddr ram_sizes[],
const unsigned int sdram_bank_sizes[])
{
ram_addr_t... | {
"code": [
" unsigned int bank_size = sdram_bank_sizes[j];",
" char name[32];",
" snprintf(name, sizeof(name), \"ppc4xx.sdram%d\", i);",
" memory_region_allocate_system_memory(&ram_memories[i], NULL,",
" ... | ram_addr_t FUNC_0(ram_addr_t ram_size, int nr_banks,
MemoryRegion ram_memories[],
hwaddr ram_bases[],
hwaddr ram_sizes[],
const unsigned int sdram_bank_sizes[])
{
ram_addr_t size_left = ... | [
"ram_addr_t FUNC_0(ram_addr_t ram_size, int nr_banks,\nMemoryRegion ram_memories[],\nhwaddr ram_bases[],\nhwaddr ram_sizes[],\nconst unsigned int sdram_bank_sizes[])\n{",
"ram_addr_t size_left = ram_size;",
"ram_addr_t base = 0;",
"int VAR_0;",
"int VAR_1;",
"for (VAR_0 = 0; VAR_0 < nr_banks; VAR_0++) {",... | [
0,
0,
0,
0,
0,
0,
0,
1,
0,
1,
1,
1,
1,
1,
1,
0,
1,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0
] | [
[
1,
3,
5,
7,
9,
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
23
],
[
25
],
[
27
],
[
31
],
[
33
],
[
35
],
[
37,
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49
],
[... |
4,672 | static int mxf_read_cryptographic_context(void *arg, AVIOContext *pb, int tag, int size, UID uid)
{
MXFCryptoContext *cryptocontext = arg;
if (size != 16)
return -1;
if (IS_KLV_KEY(uid, mxf_crypto_source_container_ul))
avio_read(pb, cryptocontext->source_container_ul, 16);
return ... | true | FFmpeg | fd34dbea58e097609ff09cf7dcc59f74930195d3 | static int mxf_read_cryptographic_context(void *arg, AVIOContext *pb, int tag, int size, UID uid)
{
MXFCryptoContext *cryptocontext = arg;
if (size != 16)
return -1;
if (IS_KLV_KEY(uid, mxf_crypto_source_container_ul))
avio_read(pb, cryptocontext->source_container_ul, 16);
return ... | {
"code": [
"static int mxf_read_cryptographic_context(void *arg, AVIOContext *pb, int tag, int size, UID uid)"
],
"line_no": [
1
]
} | static int FUNC_0(void *VAR_0, AVIOContext *VAR_1, int VAR_2, int VAR_3, UID VAR_4)
{
MXFCryptoContext *cryptocontext = VAR_0;
if (VAR_3 != 16)
return -1;
if (IS_KLV_KEY(VAR_4, mxf_crypto_source_container_ul))
avio_read(VAR_1, cryptocontext->source_container_ul, 16);
return 0;
}
| [
"static int FUNC_0(void *VAR_0, AVIOContext *VAR_1, int VAR_2, int VAR_3, UID VAR_4)\n{",
"MXFCryptoContext *cryptocontext = VAR_0;",
"if (VAR_3 != 16)\nreturn -1;",
"if (IS_KLV_KEY(VAR_4, mxf_crypto_source_container_ul))\navio_read(VAR_1, cryptocontext->source_container_ul, 16);",
"return 0;",
"}"
] | [
1,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7,
9
],
[
11,
13
],
[
15
],
[
17
]
] |
4,673 | void ff_eac3_decode_transform_coeffs_aht_ch(AC3DecodeContext *s, int ch)
{
int bin, blk, gs;
int end_bap, gaq_mode;
GetBitContext *gbc = &s->gbc;
int gaq_gain[AC3_MAX_COEFS];
gaq_mode = get_bits(gbc, 2);
end_bap = (gaq_mode < 2) ? 12 : 17;
/* if GAQ gain is used, decode gain code... | true | FFmpeg | 7b05b5093ea67a3397b0c37cf398bab471e1ce2b | void ff_eac3_decode_transform_coeffs_aht_ch(AC3DecodeContext *s, int ch)
{
int bin, blk, gs;
int end_bap, gaq_mode;
GetBitContext *gbc = &s->gbc;
int gaq_gain[AC3_MAX_COEFS];
gaq_mode = get_bits(gbc, 2);
end_bap = (gaq_mode < 2) ? 12 : 17;
gs = 0;
if (gaq_mode == EAC... | {
"code": [
"void ff_eac3_decode_transform_coeffs_aht_ch(AC3DecodeContext *s, int ch)"
],
"line_no": [
1
]
} | void FUNC_0(AC3DecodeContext *VAR_0, int VAR_1)
{
int VAR_2, VAR_3, VAR_4;
int VAR_5, VAR_6;
GetBitContext *gbc = &VAR_0->gbc;
int VAR_7[AC3_MAX_COEFS];
VAR_6 = get_bits(gbc, 2);
VAR_5 = (VAR_6 < 2) ? 12 : 17;
VAR_4 = 0;
if (VAR_6 == EAC3_GAQ_12 || VAR_6 == EAC3_GAQ_... | [
"void FUNC_0(AC3DecodeContext *VAR_0, int VAR_1)\n{",
"int VAR_2, VAR_3, VAR_4;",
"int VAR_5, VAR_6;",
"GetBitContext *gbc = &VAR_0->gbc;",
"int VAR_7[AC3_MAX_COEFS];",
"VAR_6 = get_bits(gbc, 2);",
"VAR_5 = (VAR_6 < 2) ? 12 : 17;",
"VAR_4 = 0;",
"if (VAR_6 == EAC3_GAQ_12 || VAR_6 == EAC3_GAQ_14) {",... | [
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... | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
15
],
[
17
],
[
25
],
[
27
],
[
31
],
[
33,
35
],
[
37
],
[
39
],
[
43
],
[
45
],
[
47
],
[
49
],
[
51
],
[
53
],
[... |
4,675 | void unregister_displaychangelistener(DisplayChangeListener *dcl)
{
DisplayState *ds = dcl->ds;
trace_displaychangelistener_unregister(dcl, dcl->ops->dpy_name);
if (dcl->con) {
dcl->con->dcls--;
}
QLIST_REMOVE(dcl, next);
gui_setup_refresh(ds);
} | true | qemu | 777c5f1e436d334a57b650b6951c13d8d2799df0 | void unregister_displaychangelistener(DisplayChangeListener *dcl)
{
DisplayState *ds = dcl->ds;
trace_displaychangelistener_unregister(dcl, dcl->ops->dpy_name);
if (dcl->con) {
dcl->con->dcls--;
}
QLIST_REMOVE(dcl, next);
gui_setup_refresh(ds);
} | {
"code": [],
"line_no": []
} | void FUNC_0(DisplayChangeListener *VAR_0)
{
DisplayState *ds = VAR_0->ds;
trace_displaychangelistener_unregister(VAR_0, VAR_0->ops->dpy_name);
if (VAR_0->con) {
VAR_0->con->dcls--;
}
QLIST_REMOVE(VAR_0, next);
gui_setup_refresh(ds);
} | [
"void FUNC_0(DisplayChangeListener *VAR_0)\n{",
"DisplayState *ds = VAR_0->ds;",
"trace_displaychangelistener_unregister(VAR_0, VAR_0->ops->dpy_name);",
"if (VAR_0->con) {",
"VAR_0->con->dcls--;",
"}",
"QLIST_REMOVE(VAR_0, next);",
"gui_setup_refresh(ds);",
"}"
] | [
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
18
],
[
20
]
] |
4,677 | int avpicture_layout(const AVPicture* src, enum AVPixelFormat pix_fmt,
int width, int height,
unsigned char *dest, int dest_size)
{
int i, j, nb_planes = 0, linesizes[4];
const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(pix_fmt);
int size = avpicture_get_s... | false | FFmpeg | e2ad0b66fa273c5c823978e8f601f2c0d9ee42f8 | int avpicture_layout(const AVPicture* src, enum AVPixelFormat pix_fmt,
int width, int height,
unsigned char *dest, int dest_size)
{
int i, j, nb_planes = 0, linesizes[4];
const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(pix_fmt);
int size = avpicture_get_s... | {
"code": [],
"line_no": []
} | int FUNC_0(const AVPicture* VAR_0, enum AVPixelFormat VAR_1,
int VAR_2, int VAR_3,
unsigned char *VAR_4, int VAR_5)
{
int VAR_6, VAR_7, VAR_8 = 0, VAR_9[4];
const AVPixFmtDescriptor *VAR_10 = av_pix_fmt_desc_get(VAR_1);
int VAR_11 = avpicture_get_size(VAR_1, V... | [
"int FUNC_0(const AVPicture* VAR_0, enum AVPixelFormat VAR_1,\nint VAR_2, int VAR_3,\nunsigned char *VAR_4, int VAR_5)\n{",
"int VAR_6, VAR_7, VAR_8 = 0, VAR_9[4];",
"const AVPixFmtDescriptor *VAR_10 = av_pix_fmt_desc_get(VAR_1);",
"int VAR_11 = avpicture_get_size(VAR_1, VAR_2, VAR_3);",
"if (VAR_11 > VAR_5... | [
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
],
[
29
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
45
],
[
47
],
[
49
],
[
51
],
[
53
],
[... |
4,678 | static int pipe_open(URLContext *h, const char *filename, int flags)
{
int fd;
if (flags & URL_WRONLY) {
fd = 1;
} else {
fd = 0;
}
#if defined(__MINGW32__) || defined(CONFIG_OS2) || defined(__CYGWIN__)
setmode(fd, O_BINARY);
#endif
h->priv_data = (void *)(size_t)fd;... | false | FFmpeg | 05d00e953f4cc08273fbb5f795f4fdc307140108 | static int pipe_open(URLContext *h, const char *filename, int flags)
{
int fd;
if (flags & URL_WRONLY) {
fd = 1;
} else {
fd = 0;
}
#if defined(__MINGW32__) || defined(CONFIG_OS2) || defined(__CYGWIN__)
setmode(fd, O_BINARY);
#endif
h->priv_data = (void *)(size_t)fd;... | {
"code": [],
"line_no": []
} | static int FUNC_0(URLContext *VAR_0, const char *VAR_1, int VAR_2)
{
int VAR_3;
if (VAR_2 & URL_WRONLY) {
VAR_3 = 1;
} else {
VAR_3 = 0;
}
#if defined(__MINGW32__) || defined(CONFIG_OS2) || defined(__CYGWIN__)
setmode(VAR_3, O_BINARY);
#endif
VAR_0->priv_data = (void... | [
"static int FUNC_0(URLContext *VAR_0, const char *VAR_1, int VAR_2)\n{",
"int VAR_3;",
"if (VAR_2 & URL_WRONLY) {",
"VAR_3 = 1;",
"} else {",
"VAR_3 = 0;",
"}",
"#if defined(__MINGW32__) || defined(CONFIG_OS2) || defined(__CYGWIN__)\nsetmode(VAR_3, O_BINARY);",
"#endif\nVAR_0->priv_data = (void *)(s... | [
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
],
[
31
]
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.