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 |
|---|---|---|---|---|---|---|---|---|---|---|
15,068 | static int compare_litqobj_to_qobj(LiteralQObject *lhs, QObject *rhs)
{
if (lhs->type != qobject_type(rhs)) {
return 0;
}
switch (lhs->type) {
case QTYPE_QINT:
return lhs->value.qint == qint_get_int(qobject_to_qint(rhs));
case QTYPE_QSTRING:
return (strcmp(lhs->val... | false | qemu | 9eaaf971683c99ed197fa1b7d1a3ca9baabfb3ee | static int compare_litqobj_to_qobj(LiteralQObject *lhs, QObject *rhs)
{
if (lhs->type != qobject_type(rhs)) {
return 0;
}
switch (lhs->type) {
case QTYPE_QINT:
return lhs->value.qint == qint_get_int(qobject_to_qint(rhs));
case QTYPE_QSTRING:
return (strcmp(lhs->val... | {
"code": [],
"line_no": []
} | static int FUNC_0(LiteralQObject *VAR_0, QObject *VAR_1)
{
if (VAR_0->type != qobject_type(VAR_1)) {
return 0;
}
switch (VAR_0->type) {
case QTYPE_QINT:
return VAR_0->value.qint == qint_get_int(qobject_to_qint(VAR_1));
case QTYPE_QSTRING:
return (strcmp(VAR_0->valu... | [
"static int FUNC_0(LiteralQObject *VAR_0, QObject *VAR_1)\n{",
"if (VAR_0->type != qobject_type(VAR_1)) {",
"return 0;",
"}",
"switch (VAR_0->type) {",
"case QTYPE_QINT:\nreturn VAR_0->value.qint == qint_get_int(qobject_to_qint(VAR_1));",
"case QTYPE_QSTRING:\nreturn (strcmp(VAR_0->value.qstr, qstring_g... | [
0,
0,
0,
0,
0,
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
],
[
35
],
[
37
],
[
39
],
[
41
],
[
45
],
[
47
],
[
49
],
[
51
... |
15,070 | static void trigger_prot_fault(CPUS390XState *env, target_ulong vaddr,
uint64_t asc, int rw, bool exc)
{
uint64_t tec;
tec = vaddr | (rw == MMU_DATA_STORE ? FS_WRITE : FS_READ) | 4 | asc >> 46;
DPRINTF("%s: trans_exc_code=%016" PRIx64 "\n", __func__, tec);
if (... | false | qemu | becf8217deb2afc347d5172d9f30c8a8964b8b27 | static void trigger_prot_fault(CPUS390XState *env, target_ulong vaddr,
uint64_t asc, int rw, bool exc)
{
uint64_t tec;
tec = vaddr | (rw == MMU_DATA_STORE ? FS_WRITE : FS_READ) | 4 | asc >> 46;
DPRINTF("%s: trans_exc_code=%016" PRIx64 "\n", __func__, tec);
if (... | {
"code": [],
"line_no": []
} | static void FUNC_0(CPUS390XState *VAR_0, target_ulong VAR_1,
uint64_t VAR_2, int VAR_3, bool VAR_4)
{
uint64_t tec;
tec = VAR_1 | (VAR_3 == MMU_DATA_STORE ? FS_WRITE : FS_READ) | 4 | VAR_2 >> 46;
DPRINTF("%s: trans_exc_code=%016" PRIx64 "\n", __func__, tec);
if... | [
"static void FUNC_0(CPUS390XState *VAR_0, target_ulong VAR_1,\nuint64_t VAR_2, int VAR_3, bool VAR_4)\n{",
"uint64_t tec;",
"tec = VAR_1 | (VAR_3 == MMU_DATA_STORE ? FS_WRITE : FS_READ) | 4 | VAR_2 >> 46;",
"DPRINTF(\"%s: trans_exc_code=%016\" PRIx64 \"\\n\", __func__, tec);",
"if (!VAR_4) {",
"return;",
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
11
],
[
15
],
[
19
],
[
21
],
[
23
],
[
27
],
[
29
]
] |
15,071 | static int check_oflag_copied(BlockDriverState *bs, BdrvCheckResult *res)
{
BDRVQcowState *s = bs->opaque;
uint64_t *l2_table = qemu_blockalign(bs, s->cluster_size);
int ret;
int refcount;
int i, j;
for (i = 0; i < s->l1_size; i++) {
uint64_t l1_entry = s->l1_table[i];
... | false | qemu | e23e400ec62a03dea58ddb38479b4f1ef86f556d | static int check_oflag_copied(BlockDriverState *bs, BdrvCheckResult *res)
{
BDRVQcowState *s = bs->opaque;
uint64_t *l2_table = qemu_blockalign(bs, s->cluster_size);
int ret;
int refcount;
int i, j;
for (i = 0; i < s->l1_size; i++) {
uint64_t l1_entry = s->l1_table[i];
... | {
"code": [],
"line_no": []
} | static int FUNC_0(BlockDriverState *VAR_0, BdrvCheckResult *VAR_1)
{
BDRVQcowState *s = VAR_0->opaque;
uint64_t *l2_table = qemu_blockalign(VAR_0, s->cluster_size);
int VAR_2;
int VAR_3;
int VAR_4, VAR_5;
for (VAR_4 = 0; VAR_4 < s->l1_size; VAR_4++) {
uint64_t l1_entry = s->l1_... | [
"static int FUNC_0(BlockDriverState *VAR_0, BdrvCheckResult *VAR_1)\n{",
"BDRVQcowState *s = VAR_0->opaque;",
"uint64_t *l2_table = qemu_blockalign(VAR_0, s->cluster_size);",
"int VAR_2;",
"int VAR_3;",
"int VAR_4, VAR_5;",
"for (VAR_4 = 0; VAR_4 < s->l1_size; VAR_4++) {",
"uint64_t l1_entry = s->l1_t... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
33
],
[
35
],
[
39
],
[
41
],
[
43
],
[
45,
47,
49
],
[
51
... |
15,072 | static int map_f(BlockBackend *blk, int argc, char **argv)
{
int64_t offset;
int64_t nb_sectors, total_sectors;
char s1[64];
int64_t num;
int ret;
const char *retstr;
offset = 0;
total_sectors = blk_nb_sectors(blk);
if (total_sectors < 0) {
error_report("Failed t... | false | qemu | 6f3c90af3c50d4f839849c8ba9b6ba4e9a548c28 | static int map_f(BlockBackend *blk, int argc, char **argv)
{
int64_t offset;
int64_t nb_sectors, total_sectors;
char s1[64];
int64_t num;
int ret;
const char *retstr;
offset = 0;
total_sectors = blk_nb_sectors(blk);
if (total_sectors < 0) {
error_report("Failed t... | {
"code": [],
"line_no": []
} | static int FUNC_0(BlockBackend *VAR_0, int VAR_1, char **VAR_2)
{
int64_t offset;
int64_t nb_sectors, total_sectors;
char VAR_3[64];
int64_t num;
int VAR_4;
const char *VAR_5;
offset = 0;
total_sectors = blk_nb_sectors(VAR_0);
if (total_sectors < 0) {
error_repor... | [
"static int FUNC_0(BlockBackend *VAR_0, int VAR_1, char **VAR_2)\n{",
"int64_t offset;",
"int64_t nb_sectors, total_sectors;",
"char VAR_3[64];",
"int64_t num;",
"int VAR_4;",
"const char *VAR_5;",
"offset = 0;",
"total_sectors = blk_nb_sectors(VAR_0);",
"if (total_sectors < 0) {",
"error_report... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
19
],
[
21
],
[
23
],
[
25,
27
],
[
29
],
[
31
],
[
35
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[... |
15,073 | fdctrl_t *fdctrl_init (qemu_irq irq, int dma_chann, int mem_mapped,
target_phys_addr_t io_base,
BlockDriverState **fds)
{
fdctrl_t *fdctrl;
int io_mem;
int i;
FLOPPY_DPRINTF("init controller\n");
fdctrl = qemu_mallocz(sizeof(fdctrl_t));
if... | false | qemu | 7c560456707bfe53eb1728fcde759be7d9418b62 | fdctrl_t *fdctrl_init (qemu_irq irq, int dma_chann, int mem_mapped,
target_phys_addr_t io_base,
BlockDriverState **fds)
{
fdctrl_t *fdctrl;
int io_mem;
int i;
FLOPPY_DPRINTF("init controller\n");
fdctrl = qemu_mallocz(sizeof(fdctrl_t));
if... | {
"code": [],
"line_no": []
} | fdctrl_t *FUNC_0 (qemu_irq irq, int dma_chann, int mem_mapped,
target_phys_addr_t io_base,
BlockDriverState **fds)
{
fdctrl_t *fdctrl;
int VAR_0;
int VAR_1;
FLOPPY_DPRINTF("init controller\n");
fdctrl = qemu_mallocz(sizeof(fdctrl_t));
if (... | [
"fdctrl_t *FUNC_0 (qemu_irq irq, int dma_chann, int mem_mapped,\ntarget_phys_addr_t io_base,\nBlockDriverState **fds)\n{",
"fdctrl_t *fdctrl;",
"int VAR_0;",
"int VAR_1;",
"FLOPPY_DPRINTF(\"init controller\\n\");",
"fdctrl = qemu_mallocz(sizeof(fdctrl_t));",
"if (!fdctrl)\nreturn NULL;",
"fdctrl->fifo... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5,
7
],
[
9
],
[
11
],
[
13
],
[
17
],
[
19
],
[
21,
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35,
37
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49
... |
15,074 | static void end_frame(AVFilterLink *inlink)
{
TransContext *trans = inlink->dst->priv;
AVFilterBufferRef *inpic = inlink->cur_buf;
AVFilterBufferRef *outpic = inlink->dst->outputs[0]->out_buf;
AVFilterLink *outlink = inlink->dst->outputs[0];
int plane;
for (plane = 0; outpic->data[plan... | false | FFmpeg | 07bad27810cdd7d3171cbd542119aa051646377c | static void end_frame(AVFilterLink *inlink)
{
TransContext *trans = inlink->dst->priv;
AVFilterBufferRef *inpic = inlink->cur_buf;
AVFilterBufferRef *outpic = inlink->dst->outputs[0]->out_buf;
AVFilterLink *outlink = inlink->dst->outputs[0];
int plane;
for (plane = 0; outpic->data[plan... | {
"code": [],
"line_no": []
} | static void FUNC_0(AVFilterLink *VAR_0)
{
TransContext *trans = VAR_0->dst->priv;
AVFilterBufferRef *inpic = VAR_0->cur_buf;
AVFilterBufferRef *outpic = VAR_0->dst->outputs[0]->out_buf;
AVFilterLink *outlink = VAR_0->dst->outputs[0];
int VAR_1;
for (VAR_1 = 0; outpic->data[VAR_1]; VAR_... | [
"static void FUNC_0(AVFilterLink *VAR_0)\n{",
"TransContext *trans = VAR_0->dst->priv;",
"AVFilterBufferRef *inpic = VAR_0->cur_buf;",
"AVFilterBufferRef *outpic = VAR_0->dst->outputs[0]->out_buf;",
"AVFilterLink *outlink = VAR_0->dst->outputs[0];",
"int VAR_1;",
"for (VAR_1 = 0; outpic->data[VAR_1]; V... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
39
],
[
41
],
[
45
],
[
47
... |
15,075 | void *block_job_create(const BlockJobDriver *driver, BlockDriverState *bs,
int64_t speed, BlockDriverCompletionFunc *cb,
void *opaque, Error **errp)
{
BlockJob *job;
if (bs->job || bdrv_in_use(bs)) {
error_set(errp, QERR_DEVICE_IN_USE, bdrv_get_devic... | false | qemu | 3718d8ab65f68de2acccbe6a315907805f54e3cc | void *block_job_create(const BlockJobDriver *driver, BlockDriverState *bs,
int64_t speed, BlockDriverCompletionFunc *cb,
void *opaque, Error **errp)
{
BlockJob *job;
if (bs->job || bdrv_in_use(bs)) {
error_set(errp, QERR_DEVICE_IN_USE, bdrv_get_devic... | {
"code": [],
"line_no": []
} | void *FUNC_0(const BlockJobDriver *VAR_0, BlockDriverState *VAR_1,
int64_t VAR_2, BlockDriverCompletionFunc *VAR_3,
void *VAR_4, Error **VAR_5)
{
BlockJob *job;
if (VAR_1->job || bdrv_in_use(VAR_1)) {
error_set(VAR_5, QERR_DEVICE_IN_USE, bdrv_get_dev... | [
"void *FUNC_0(const BlockJobDriver *VAR_0, BlockDriverState *VAR_1,\nint64_t VAR_2, BlockDriverCompletionFunc *VAR_3,\nvoid *VAR_4, Error **VAR_5)\n{",
"BlockJob *job;",
"if (VAR_1->job || bdrv_in_use(VAR_1)) {",
"error_set(VAR_5, QERR_DEVICE_IN_USE, bdrv_get_device_name(VAR_1));",
"return NULL;",
"}",
... | [
0,
0,
0,
0,
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
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
45
],
[
47
],
[
51
],
[
53
... |
15,076 | static int apb_pci_bridge_initfn(PCIDevice *dev)
{
int rc;
rc = pci_bridge_initfn(dev);
if (rc < 0) {
return rc;
}
pci_config_set_vendor_id(dev->config, PCI_VENDOR_ID_SUN);
pci_config_set_device_id(dev->config, PCI_DEVICE_ID_SUN_SIMBA);
/*
* command register:
... | false | qemu | 92f9a4f13ea29de4644bd0b077643e1dff96ab29 | static int apb_pci_bridge_initfn(PCIDevice *dev)
{
int rc;
rc = pci_bridge_initfn(dev);
if (rc < 0) {
return rc;
}
pci_config_set_vendor_id(dev->config, PCI_VENDOR_ID_SUN);
pci_config_set_device_id(dev->config, PCI_DEVICE_ID_SUN_SIMBA);
pci_set_wo... | {
"code": [],
"line_no": []
} | static int FUNC_0(PCIDevice *VAR_0)
{
int VAR_1;
VAR_1 = pci_bridge_initfn(VAR_0);
if (VAR_1 < 0) {
return VAR_1;
}
pci_config_set_vendor_id(VAR_0->config, PCI_VENDOR_ID_SUN);
pci_config_set_device_id(VAR_0->config, PCI_DEVICE_ID_SUN_SIMBA);
pci_s... | [
"static int FUNC_0(PCIDevice *VAR_0)\n{",
"int VAR_1;",
"VAR_1 = pci_bridge_initfn(VAR_0);",
"if (VAR_1 < 0) {",
"return VAR_1;",
"}",
"pci_config_set_vendor_id(VAR_0->config, PCI_VENDOR_ID_SUN);",
"pci_config_set_device_id(VAR_0->config, PCI_DEVICE_ID_SUN_SIMBA);",
"pci_set_word(VAR_0->config + PCI... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
],
[
13
],
[
15
],
[
19
],
[
21
],
[
43,
45
],
[
47,
49,
51
],
[
53
],
[
55
],
[
57
]
] |
15,078 | static int proxy_rename(FsContext *ctx, const char *oldpath,
const char *newpath)
{
int retval;
V9fsString oldname, newname;
v9fs_string_init(&oldname);
v9fs_string_init(&newname);
v9fs_string_sprintf(&oldname, "%s", oldpath);
v9fs_string_sprintf(&newname, "%s... | false | qemu | 494a8ebe713055d3946183f4b395f85a18b43e9e | static int proxy_rename(FsContext *ctx, const char *oldpath,
const char *newpath)
{
int retval;
V9fsString oldname, newname;
v9fs_string_init(&oldname);
v9fs_string_init(&newname);
v9fs_string_sprintf(&oldname, "%s", oldpath);
v9fs_string_sprintf(&newname, "%s... | {
"code": [],
"line_no": []
} | static int FUNC_0(FsContext *VAR_0, const char *VAR_1,
const char *VAR_2)
{
int VAR_3;
V9fsString oldname, newname;
v9fs_string_init(&oldname);
v9fs_string_init(&newname);
v9fs_string_sprintf(&oldname, "%s", VAR_1);
v9fs_string_sprintf(&newname, "%s", VAR_2);
... | [
"static int FUNC_0(FsContext *VAR_0, const char *VAR_1,\nconst char *VAR_2)\n{",
"int VAR_3;",
"V9fsString oldname, newname;",
"v9fs_string_init(&oldname);",
"v9fs_string_init(&newname);",
"v9fs_string_sprintf(&oldname, \"%s\", VAR_1);",
"v9fs_string_sprintf(&newname, \"%s\", VAR_2);",
"VAR_3 = v9fs_r... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
19
],
[
21
],
[
23,
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
]
] |
15,079 | void helper_memalign(uint32_t addr, uint32_t dr, uint32_t wr, uint32_t mask)
{
if (addr & mask) {
qemu_log("unaligned access addr=%x mask=%x, wr=%d\n",
addr, mask, wr);
if (!(env->sregs[SR_MSR] & MSR_EE)) {
return;
}
env-... | false | qemu | 97f90cbfe810bb153fc44bde732d9639610783bb | void helper_memalign(uint32_t addr, uint32_t dr, uint32_t wr, uint32_t mask)
{
if (addr & mask) {
qemu_log("unaligned access addr=%x mask=%x, wr=%d\n",
addr, mask, wr);
if (!(env->sregs[SR_MSR] & MSR_EE)) {
return;
}
env-... | {
"code": [],
"line_no": []
} | void FUNC_0(uint32_t VAR_0, uint32_t VAR_1, uint32_t VAR_2, uint32_t VAR_3)
{
if (VAR_0 & VAR_3) {
qemu_log("unaligned access VAR_0=%x VAR_3=%x, VAR_2=%d\n",
VAR_0, VAR_3, VAR_2);
if (!(env->sregs[SR_MSR] & MSR_EE)) {
return;
}
... | [
"void FUNC_0(uint32_t VAR_0, uint32_t VAR_1, uint32_t VAR_2, uint32_t VAR_3)\n{",
"if (VAR_0 & VAR_3) {",
"qemu_log(\"unaligned access VAR_0=%x VAR_3=%x, VAR_2=%d\\n\",\nVAR_0, VAR_3, VAR_2);",
"if (!(env->sregs[SR_MSR] & MSR_EE)) {",
"return;",
"}",
"env->sregs[SR_ESR] = ESR_EC_UNALIGNED_DATA | (VAR_2 ... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7,
9
],
[
11
],
[
13
],
[
15
],
[
19,
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
]
] |
15,080 | static void gdb_breakpoint_remove_all(CPUState *env)
{
cpu_breakpoint_remove_all(env, BP_GDB);
#ifndef CONFIG_USER_ONLY
cpu_watchpoint_remove_all(env, BP_GDB);
#endif
}
| false | qemu | 880a7578381d1c7ed4d41c7599ae3cc06567a824 | static void gdb_breakpoint_remove_all(CPUState *env)
{
cpu_breakpoint_remove_all(env, BP_GDB);
#ifndef CONFIG_USER_ONLY
cpu_watchpoint_remove_all(env, BP_GDB);
#endif
}
| {
"code": [],
"line_no": []
} | static void FUNC_0(CPUState *VAR_0)
{
cpu_breakpoint_remove_all(VAR_0, BP_GDB);
#ifndef CONFIG_USER_ONLY
cpu_watchpoint_remove_all(VAR_0, BP_GDB);
#endif
}
| [
"static void FUNC_0(CPUState *VAR_0)\n{",
"cpu_breakpoint_remove_all(VAR_0, BP_GDB);",
"#ifndef CONFIG_USER_ONLY\ncpu_watchpoint_remove_all(VAR_0, BP_GDB);",
"#endif\n}"
] | [
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7,
9
],
[
11,
13
]
] |
15,081 | static void handle_pending_signal(CPUArchState *cpu_env, int sig)
{
CPUState *cpu = ENV_GET_CPU(cpu_env);
abi_ulong handler;
sigset_t set;
target_sigset_t target_old_set;
struct target_sigaction *sa;
TaskState *ts = cpu->opaque;
struct emulated_sigtable *k = &ts->sigtab[sig - 1];
... | false | qemu | 655ed67c2a248cf0a887229d8492d6ddc0518545 | static void handle_pending_signal(CPUArchState *cpu_env, int sig)
{
CPUState *cpu = ENV_GET_CPU(cpu_env);
abi_ulong handler;
sigset_t set;
target_sigset_t target_old_set;
struct target_sigaction *sa;
TaskState *ts = cpu->opaque;
struct emulated_sigtable *k = &ts->sigtab[sig - 1];
... | {
"code": [],
"line_no": []
} | static void FUNC_0(CPUArchState *VAR_0, int VAR_1)
{
CPUState *cpu = ENV_GET_CPU(VAR_0);
abi_ulong handler;
sigset_t set;
target_sigset_t target_old_set;
struct target_sigaction *VAR_2;
TaskState *ts = cpu->opaque;
struct emulated_sigtable *VAR_3 = &ts->sigtab[VAR_1 - 1];
trac... | [
"static void FUNC_0(CPUArchState *VAR_0, int VAR_1)\n{",
"CPUState *cpu = ENV_GET_CPU(VAR_0);",
"abi_ulong handler;",
"sigset_t set;",
"target_sigset_t target_old_set;",
"struct target_sigaction *VAR_2;",
"TaskState *ts = cpu->opaque;",
"struct emulated_sigtable *VAR_3 = &ts->sigtab[VAR_1 - 1];",
"t... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
21
],
[
25
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
47
],
[
57
... |
15,083 | static void pxa2xx_gpio_handler_update(PXA2xxGPIOInfo *s) {
uint32_t level, diff;
int i, bit, line;
for (i = 0; i < PXA2XX_GPIO_BANKS; i ++) {
level = s->olevel[i] & s->dir[i];
for (diff = s->prev_level[i] ^ level; diff; diff ^= 1 << bit) {
bit = ffs(diff) - 1;
... | false | qemu | 786a4ea82ec9c87e3a895cf41081029b285a5fe5 | static void pxa2xx_gpio_handler_update(PXA2xxGPIOInfo *s) {
uint32_t level, diff;
int i, bit, line;
for (i = 0; i < PXA2XX_GPIO_BANKS; i ++) {
level = s->olevel[i] & s->dir[i];
for (diff = s->prev_level[i] ^ level; diff; diff ^= 1 << bit) {
bit = ffs(diff) - 1;
... | {
"code": [],
"line_no": []
} | static void FUNC_0(PXA2xxGPIOInfo *VAR_0) {
uint32_t level, diff;
int VAR_1, VAR_2, VAR_3;
for (VAR_1 = 0; VAR_1 < PXA2XX_GPIO_BANKS; VAR_1 ++) {
level = VAR_0->olevel[VAR_1] & VAR_0->dir[VAR_1];
for (diff = VAR_0->prev_level[VAR_1] ^ level; diff; diff ^= 1 << VAR_2) {
VA... | [
"static void FUNC_0(PXA2xxGPIOInfo *VAR_0) {",
"uint32_t level, diff;",
"int VAR_1, VAR_2, VAR_3;",
"for (VAR_1 = 0; VAR_1 < PXA2XX_GPIO_BANKS; VAR_1 ++) {",
"level = VAR_0->olevel[VAR_1] & VAR_0->dir[VAR_1];",
"for (diff = VAR_0->prev_level[VAR_1] ^ level; diff; diff ^= 1 << VAR_2) {",
"VAR_2 = ffs(dif... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1
],
[
3
],
[
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
25
],
[
27
],
[
29
]
] |
15,084 | int kvm_init(int smp_cpus)
{
static const char upgrade_note[] =
"Please upgrade to at least kernel 2.6.29 or recent kvm-kmod\n"
"(see http://sourceforge.net/projects/kvm).\n";
KVMState *s;
int ret;
int i;
if (smp_cpus > 1) {
fprintf(stderr, "No SMP KVM support, use... | false | qemu | 72cf2d4f0e181d0d3a3122e04129c58a95da713e | int kvm_init(int smp_cpus)
{
static const char upgrade_note[] =
"Please upgrade to at least kernel 2.6.29 or recent kvm-kmod\n"
"(see http:
KVMState *s;
int ret;
int i;
if (smp_cpus > 1) {
fprintf(stderr, "No SMP KVM support, use '-smp 1'\n");
return -EINV... | {
"code": [],
"line_no": []
} | int FUNC_0(int VAR_0)
{
static const char VAR_1[] =
"Please upgrade to at least kernel 2.6.29 or recent kvm-kmod\n"
"(see http:
KVMState *s;
int VAR_2;
int VAR_3;
if (VAR_0 > 1) {
fprintf(stderr, "No SMP KVM support, use '-smp 1'\n");
return -EINVAL;
... | [
"int FUNC_0(int VAR_0)\n{",
"static const char VAR_1[] =\n\"Please upgrade to at least kernel 2.6.29 or recent kvm-kmod\\n\"\n\"(see http:\nKVMState *s;",
"int VAR_2;",
"int VAR_3;",
"if (VAR_0 > 1) {",
"fprintf(stderr, \"No SMP KVM support, use '-smp 1'\\n\");",
"return -EINVAL;",
"}",
"s = qemu_ma... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
29
],
[
33,
35
],
[
37,
39
],
[
41
],
[
45
],
[
47
],
[
49
],
[
51
],
[
53
],
[... |
15,085 | static void unpack_alpha(GetBitContext *gb, uint16_t *dst, int num_coeffs,
const int num_bits)
{
const int mask = (1 << num_bits) - 1;
int i, idx, val, alpha_val;
idx = 0;
alpha_val = mask;
do {
do {
if (get_bits1(gb))
va... | false | FFmpeg | 30df9789a9745d8e4b1afc10d1a983bfc8816eb9 | static void unpack_alpha(GetBitContext *gb, uint16_t *dst, int num_coeffs,
const int num_bits)
{
const int mask = (1 << num_bits) - 1;
int i, idx, val, alpha_val;
idx = 0;
alpha_val = mask;
do {
do {
if (get_bits1(gb))
va... | {
"code": [],
"line_no": []
} | static void FUNC_0(GetBitContext *VAR_0, uint16_t *VAR_1, int VAR_2,
const int VAR_3)
{
const int VAR_4 = (1 << VAR_3) - 1;
int VAR_5, VAR_6, VAR_7, VAR_8;
VAR_6 = 0;
VAR_8 = VAR_4;
do {
do {
if (get_bits1(VAR_0))
VAR_7 =... | [
"static void FUNC_0(GetBitContext *VAR_0, uint16_t *VAR_1, int VAR_2,\nconst int VAR_3)\n{",
"const int VAR_4 = (1 << VAR_3) - 1;",
"int VAR_5, VAR_6, VAR_7, VAR_8;",
"VAR_6 = 0;",
"VAR_8 = VAR_4;",
"do {",
"do {",
"if (get_bits1(VAR_0))\nVAR_7 = get_bits(VAR_0, VAR_3);",
"else {",
"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
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21,
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35,
37
],
[
39
],
[
41
],
[
43,
45
],
[
47,... |
15,087 | static int virtconsole_initfn(VirtIOSerialPort *port)
{
VirtConsole *vcon = DO_UPCAST(VirtConsole, port, port);
VirtIOSerialPortInfo *info = DO_UPCAST(VirtIOSerialPortInfo, qdev,
vcon->port.dev.info);
if (port->id == 0 && !info->is_console) {
error_... | false | qemu | 05e7af694ce00dafdc464ca70306fa9dd6f78dcd | static int virtconsole_initfn(VirtIOSerialPort *port)
{
VirtConsole *vcon = DO_UPCAST(VirtConsole, port, port);
VirtIOSerialPortInfo *info = DO_UPCAST(VirtIOSerialPortInfo, qdev,
vcon->port.dev.info);
if (port->id == 0 && !info->is_console) {
error_... | {
"code": [],
"line_no": []
} | static int FUNC_0(VirtIOSerialPort *VAR_0)
{
VirtConsole *vcon = DO_UPCAST(VirtConsole, VAR_0, VAR_0);
VirtIOSerialPortInfo *info = DO_UPCAST(VirtIOSerialPortInfo, qdev,
vcon->VAR_0.dev.info);
if (VAR_0->id == 0 && !info->is_console) {
error_report(... | [
"static int FUNC_0(VirtIOSerialPort *VAR_0)\n{",
"VirtConsole *vcon = DO_UPCAST(VirtConsole, VAR_0, VAR_0);",
"VirtIOSerialPortInfo *info = DO_UPCAST(VirtIOSerialPortInfo, qdev,\nvcon->VAR_0.dev.info);",
"if (VAR_0->id == 0 && !info->is_console) {",
"error_report(\"Port number 0 on virtio-serial devices res... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7,
9
],
[
13
],
[
15
],
[
17
],
[
19
],
[
23
],
[
25,
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
39
],
[
41
]
] |
15,088 | static int ppc_hash32_get_physical_address(CPUPPCState *env, struct mmu_ctx_hash32 *ctx,
target_ulong eaddr, int rw,
int access_type)
{
bool real_mode = (access_type == ACCESS_CODE && msr_ir == 0)
|| (access_type != A... | false | qemu | 91cda45b69e45a089f9989979a65db3f710c9925 | static int ppc_hash32_get_physical_address(CPUPPCState *env, struct mmu_ctx_hash32 *ctx,
target_ulong eaddr, int rw,
int access_type)
{
bool real_mode = (access_type == ACCESS_CODE && msr_ir == 0)
|| (access_type != A... | {
"code": [],
"line_no": []
} | static int FUNC_0(CPUPPCState *VAR_0, struct mmu_ctx_hash32 *VAR_1,
target_ulong VAR_2, int VAR_3,
int VAR_4)
{
bool real_mode = (VAR_4 == ACCESS_CODE && msr_ir == 0)
|| (VAR_4 != ACCESS_CODE && msr_dr == 0);
i... | [
"static int FUNC_0(CPUPPCState *VAR_0, struct mmu_ctx_hash32 *VAR_1,\ntarget_ulong VAR_2, int VAR_3,\nint VAR_4)\n{",
"bool real_mode = (VAR_4 == ACCESS_CODE && msr_ir == 0)\n|| (VAR_4 != ACCESS_CODE && msr_dr == 0);",
"if (real_mode) {",
"VAR_1->raddr = VAR_2;",
"VAR_1->prot = PAGE_READ | PAGE_EXEC | PAGE_... | [
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
],
[
31
],
[
33
],
[
35
],
[
37
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49
]
] |
15,089 | static int vmdk_read(BlockDriverState *bs, int64_t sector_num,
uint8_t *buf, int nb_sectors)
{
BDRVVmdkState *s = bs->opaque;
int ret;
uint64_t n, index_in_cluster;
VmdkExtent *extent = NULL;
uint64_t cluster_offset;
while (nb_sectors > 0) {
extent = find_e... | false | qemu | ae261c86aaed62e7acddafab8262a2bf286d40b7 | static int vmdk_read(BlockDriverState *bs, int64_t sector_num,
uint8_t *buf, int nb_sectors)
{
BDRVVmdkState *s = bs->opaque;
int ret;
uint64_t n, index_in_cluster;
VmdkExtent *extent = NULL;
uint64_t cluster_offset;
while (nb_sectors > 0) {
extent = find_e... | {
"code": [],
"line_no": []
} | static int FUNC_0(BlockDriverState *VAR_0, int64_t VAR_1,
uint8_t *VAR_2, int VAR_3)
{
BDRVVmdkState *s = VAR_0->opaque;
int VAR_4;
uint64_t n, index_in_cluster;
VmdkExtent *extent = NULL;
uint64_t cluster_offset;
while (VAR_3 > 0) {
extent = find_extent(s,... | [
"static int FUNC_0(BlockDriverState *VAR_0, int64_t VAR_1,\nuint8_t *VAR_2, int VAR_3)\n{",
"BDRVVmdkState *s = VAR_0->opaque;",
"int VAR_4;",
"uint64_t n, index_in_cluster;",
"VmdkExtent *extent = NULL;",
"uint64_t cluster_offset;",
"while (VAR_3 > 0) {",
"extent = find_extent(s, VAR_1, extent);",
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29,
31,
33
],
[
35
],
[
37
],
[
39,
41
],
[
43
],
[
47
],
[
49,... |
15,090 | static bool migrate_params_check(MigrationParameters *params, Error **errp)
{
if (params->has_compress_level &&
(params->compress_level < 0 || params->compress_level > 9)) {
error_setg(errp, QERR_INVALID_PARAMETER_VALUE, "compress_level",
"is invalid, it should be in the rang... | false | qemu | 741d4086c856320807a2575389d7c0505578270b | static bool migrate_params_check(MigrationParameters *params, Error **errp)
{
if (params->has_compress_level &&
(params->compress_level < 0 || params->compress_level > 9)) {
error_setg(errp, QERR_INVALID_PARAMETER_VALUE, "compress_level",
"is invalid, it should be in the rang... | {
"code": [],
"line_no": []
} | static bool FUNC_0(MigrationParameters *params, Error **errp)
{
if (params->has_compress_level &&
(params->compress_level < 0 || params->compress_level > 9)) {
error_setg(errp, QERR_INVALID_PARAMETER_VALUE, "compress_level",
"is invalid, it should be in the range of 0 to 9");... | [
"static bool FUNC_0(MigrationParameters *params, Error **errp)\n{",
"if (params->has_compress_level &&\n(params->compress_level < 0 || params->compress_level > 9)) {",
"error_setg(errp, QERR_INVALID_PARAMETER_VALUE, \"compress_level\",\n\"is invalid, it should be in the range of 0 to 9\");",
"return false;",
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5,
7
],
[
9,
11
],
[
13
],
[
15
],
[
19,
21
],
[
23,
25,
27
],
[
29
],
[
31
],
[
35,
37
],
[
39,
41,
43
],
[
45
],
[
47
],
[
51,
53,
55
],
[
57,... |
15,091 | int add_exec(struct ex_list **ex_ptr, int do_pty, char *exec,
struct in_addr addr, int port)
{
struct ex_list *tmp_ptr;
/* First, check if the port is "bound" */
for (tmp_ptr = *ex_ptr; tmp_ptr; tmp_ptr = tmp_ptr->ex_next) {
if (port == tmp_ptr->ex_fport &&
addr.s_addr == tmp_ptr->ex_ad... | true | qemu | 2fd5d864099dd38b43b595e9e3375dad2f76049b | int add_exec(struct ex_list **ex_ptr, int do_pty, char *exec,
struct in_addr addr, int port)
{
struct ex_list *tmp_ptr;
for (tmp_ptr = *ex_ptr; tmp_ptr; tmp_ptr = tmp_ptr->ex_next) {
if (port == tmp_ptr->ex_fport &&
addr.s_addr == tmp_ptr->ex_addr.s_addr)
return -1;
}
tmp_ptr... | {
"code": [
"\t*ex_ptr = (struct ex_list *)malloc(sizeof(struct ex_list));",
"\t(*ex_ptr)->ex_exec = (do_pty == 3) ? exec : strdup(exec);"
],
"line_no": [
27,
35
]
} | int FUNC_0(struct ex_list **VAR_0, int VAR_1, char *VAR_2,
struct in_addr VAR_3, int VAR_4)
{
struct ex_list *VAR_5;
for (VAR_5 = *VAR_0; VAR_5; VAR_5 = VAR_5->ex_next) {
if (VAR_4 == VAR_5->ex_fport &&
VAR_3.s_addr == VAR_5->ex_addr.s_addr)
return -1;
}
VAR_5 = *VAR_0;
*VA... | [
"int FUNC_0(struct ex_list **VAR_0, int VAR_1, char *VAR_2,\nstruct in_addr VAR_3, int VAR_4)\n{",
"struct ex_list *VAR_5;",
"for (VAR_5 = *VAR_0; VAR_5; VAR_5 = VAR_5->ex_next) {",
"if (VAR_4 == VAR_5->ex_fport &&\nVAR_3.s_addr == VAR_5->ex_addr.s_addr)\nreturn -1;",
"}",
"VAR_5 = *VAR_0;",
"*VAR_0 = (... | [
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
1,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
13
],
[
15,
17,
19
],
[
21
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
]
] |
15,092 | static void dec_sextb(DisasContext *dc)
{
LOG_DIS("sextb r%d, r%d\n", dc->r2, dc->r0);
if (!(dc->env->features & LM32_FEATURE_SIGN_EXTEND)) {
cpu_abort(dc->env, "hardware sign extender is not available\n");
}
tcg_gen_ext8s_tl(cpu_R[dc->r2], cpu_R[dc->r0]);
}
| true | qemu | 3604a76fea6ff37738d4a8f596be38407be74a83 | static void dec_sextb(DisasContext *dc)
{
LOG_DIS("sextb r%d, r%d\n", dc->r2, dc->r0);
if (!(dc->env->features & LM32_FEATURE_SIGN_EXTEND)) {
cpu_abort(dc->env, "hardware sign extender is not available\n");
}
tcg_gen_ext8s_tl(cpu_R[dc->r2], cpu_R[dc->r0]);
}
| {
"code": [
" cpu_abort(dc->env, \"hardware sign extender is not available\\n\");",
" cpu_abort(dc->env, \"hardware sign extender is not available\\n\");"
],
"line_no": [
11,
11
]
} | static void FUNC_0(DisasContext *VAR_0)
{
LOG_DIS("sextb r%d, r%d\n", VAR_0->r2, VAR_0->r0);
if (!(VAR_0->env->features & LM32_FEATURE_SIGN_EXTEND)) {
cpu_abort(VAR_0->env, "hardware sign extender is not available\n");
}
tcg_gen_ext8s_tl(cpu_R[VAR_0->r2], cpu_R[VAR_0->r0]);
}
| [
"static void FUNC_0(DisasContext *VAR_0)\n{",
"LOG_DIS(\"sextb r%d, r%d\\n\", VAR_0->r2, VAR_0->r0);",
"if (!(VAR_0->env->features & LM32_FEATURE_SIGN_EXTEND)) {",
"cpu_abort(VAR_0->env, \"hardware sign extender is not available\\n\");",
"}",
"tcg_gen_ext8s_tl(cpu_R[VAR_0->r2], cpu_R[VAR_0->r0]);",
"}"
... | [
0,
0,
0,
1,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
],
[
13
],
[
17
],
[
19
]
] |
15,093 | static void mdct512(AC3MDCTContext *mdct, int32_t *out, int16_t *in)
{
int i, re, im, n, n2, n4;
int16_t *rot = mdct->rot_tmp;
IComplex *x = mdct->cplx_tmp;
n = 1 << mdct->nbits;
n2 = n >> 1;
n4 = n >> 2;
/* shift to simplify computations */
for (i = 0; i <n4; i++)
... | true | FFmpeg | 323e6fead07c75f418e4b60704a4f437bb3483b2 | static void mdct512(AC3MDCTContext *mdct, int32_t *out, int16_t *in)
{
int i, re, im, n, n2, n4;
int16_t *rot = mdct->rot_tmp;
IComplex *x = mdct->cplx_tmp;
n = 1 << mdct->nbits;
n2 = n >> 1;
n4 = n >> 2;
for (i = 0; i <n4; i++)
rot[i] = -in[i + 3*n4];
memcp... | {
"code": [
" CMUL(x[i].re, x[i].im, re, im, -mdct->xcos1[i], mdct->xsin1[i]);",
" CMUL(out[n2-1-2*i], out[2*i], re, im, mdct->xsin1[i], mdct->xcos1[i]);"
],
"line_no": [
39,
57
]
} | static void FUNC_0(AC3MDCTContext *VAR_0, int32_t *VAR_1, int16_t *VAR_2)
{
int VAR_3, VAR_4, VAR_5, VAR_6, VAR_7, VAR_8;
int16_t *rot = VAR_0->rot_tmp;
IComplex *x = VAR_0->cplx_tmp;
VAR_6 = 1 << VAR_0->nbits;
VAR_7 = VAR_6 >> 1;
VAR_8 = VAR_6 >> 2;
for (VAR_3 = 0; VAR_3... | [
"static void FUNC_0(AC3MDCTContext *VAR_0, int32_t *VAR_1, int16_t *VAR_2)\n{",
"int VAR_3, VAR_4, VAR_5, VAR_6, VAR_7, VAR_8;",
"int16_t *rot = VAR_0->rot_tmp;",
"IComplex *x = VAR_0->cplx_tmp;",
"VAR_6 = 1 << VAR_0->nbits;",
"VAR_7 = VAR_6 >> 1;",
"VAR_8 = VAR_6 >> 2;",
"for (VAR_3 = 0; VAR_3 <VAR... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
1,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
17
],
[
23
],
[
25
],
[
27
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
45
],
[
51
],
[
53
],
[
55
],
[
57
... |
15,095 | static uint32_t pm_ioport_readw(void *opaque, uint32_t addr)
{
VT686PMState *s = opaque;
uint32_t val;
addr &= 0x0f;
switch (addr) {
case 0x00:
val = acpi_pm1_evt_get_sts(&s->ar, s->ar.tmr.overflow_time);
break;
case 0x02:
val = s->ar.pm1.evt.en;
brea... | true | qemu | 2886be1b01c274570fa139748a402207482405bd | static uint32_t pm_ioport_readw(void *opaque, uint32_t addr)
{
VT686PMState *s = opaque;
uint32_t val;
addr &= 0x0f;
switch (addr) {
case 0x00:
val = acpi_pm1_evt_get_sts(&s->ar, s->ar.tmr.overflow_time);
break;
case 0x02:
val = s->ar.pm1.evt.en;
brea... | {
"code": [
" val = acpi_pm1_evt_get_sts(&s->ar, s->ar.tmr.overflow_time);",
" val = acpi_pm1_evt_get_sts(&s->ar, s->ar.tmr.overflow_time);"
],
"line_no": [
17,
17
]
} | static uint32_t FUNC_0(void *opaque, uint32_t addr)
{
VT686PMState *s = opaque;
uint32_t val;
addr &= 0x0f;
switch (addr) {
case 0x00:
val = acpi_pm1_evt_get_sts(&s->ar, s->ar.tmr.overflow_time);
break;
case 0x02:
val = s->ar.pm1.evt.en;
break;
c... | [
"static uint32_t FUNC_0(void *opaque, uint32_t addr)\n{",
"VT686PMState *s = opaque;",
"uint32_t val;",
"addr &= 0x0f;",
"switch (addr) {",
"case 0x00:\nval = acpi_pm1_evt_get_sts(&s->ar, s->ar.tmr.overflow_time);",
"break;",
"case 0x02:\nval = s->ar.pm1.evt.en;",
"break;",
"case 0x04:\nval = s->a... | [
0,
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
],
[
33,
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
]
] |
15,096 | static int get_cod(Jpeg2000DecoderContext *s, Jpeg2000CodingStyle *c,
uint8_t *properties)
{
Jpeg2000CodingStyle tmp;
int compno, ret;
if (bytestream2_get_bytes_left(&s->g) < 5)
tmp.csty = bytestream2_get_byteu(&s->g);
// get progression order
tmp.prog_order = bytestream2_get_... | true | FFmpeg | cf04af2086be105ff86088357b83d672d38417d9 | static int get_cod(Jpeg2000DecoderContext *s, Jpeg2000CodingStyle *c,
uint8_t *properties)
{
Jpeg2000CodingStyle tmp;
int compno, ret;
if (bytestream2_get_bytes_left(&s->g) < 5)
tmp.csty = bytestream2_get_byteu(&s->g);
tmp.prog_order = bytestream2_get_byteu(&s->g);
tmp.nl... | {
"code": [],
"line_no": []
} | static int FUNC_0(Jpeg2000DecoderContext *VAR_0, Jpeg2000CodingStyle *VAR_1,
uint8_t *VAR_2)
{
Jpeg2000CodingStyle tmp;
int VAR_3, VAR_4;
if (bytestream2_get_bytes_left(&VAR_0->g) < 5)
tmp.csty = bytestream2_get_byteu(&VAR_0->g);
tmp.prog_order = bytestream2_get_byteu(&VAR_0-... | [
"static int FUNC_0(Jpeg2000DecoderContext *VAR_0, Jpeg2000CodingStyle *VAR_1,\nuint8_t *VAR_2)\n{",
"Jpeg2000CodingStyle tmp;",
"int VAR_3, VAR_4;",
"if (bytestream2_get_bytes_left(&VAR_0->g) < 5)\ntmp.csty = bytestream2_get_byteu(&VAR_0->g);",
"tmp.prog_order = bytestream2_get_byteu(&VAR_0->g);",
"tmp.nl... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
2,
3
],
[
4
],
[
5
],
[
6,
7
],
[
9
],
[
10
],
[
11
],
[
12,
13
],
[
14
],
[
15,
16
],
[
17
]
] |
15,097 | static av_cold void construct_perm_table(TwinContext *tctx,enum FrameType ftype)
{
int block_size;
const ModeTab *mtab = tctx->mtab;
int size = tctx->avctx->channels*mtab->fmode[ftype].sub;
int16_t *tmp_perm = (int16_t *) tctx->tmp_buf;
if (ftype == FT_PPC) {
size = tctx->avctx->ch... | true | FFmpeg | 4bf2e7c5f1c0ad3997fd7c9859c16db8e4e16df6 | static av_cold void construct_perm_table(TwinContext *tctx,enum FrameType ftype)
{
int block_size;
const ModeTab *mtab = tctx->mtab;
int size = tctx->avctx->channels*mtab->fmode[ftype].sub;
int16_t *tmp_perm = (int16_t *) tctx->tmp_buf;
if (ftype == FT_PPC) {
size = tctx->avctx->ch... | {
"code": [
" int size = tctx->avctx->channels*mtab->fmode[ftype].sub;",
" } else"
],
"line_no": [
9,
21
]
} | static av_cold void FUNC_0(TwinContext *tctx,enum FrameType ftype)
{
int VAR_0;
const ModeTab *VAR_1 = tctx->VAR_1;
int VAR_2 = tctx->avctx->channels*VAR_1->fmode[ftype].sub;
int16_t *tmp_perm = (int16_t *) tctx->tmp_buf;
if (ftype == FT_PPC) {
VAR_2 = tctx->avctx->channels;
... | [
"static av_cold void FUNC_0(TwinContext *tctx,enum FrameType ftype)\n{",
"int VAR_0;",
"const ModeTab *VAR_1 = tctx->VAR_1;",
"int VAR_2 = tctx->avctx->channels*VAR_1->fmode[ftype].sub;",
"int16_t *tmp_perm = (int16_t *) tctx->tmp_buf;",
"if (ftype == FT_PPC) {",
"VAR_2 = tctx->avctx->channels;",
"VA... | [
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
27,
29,
31
],
[
35,
37
],
[
41,
43
],
[
45
]
] |
15,098 | yuv2rgb_1_c_template(SwsContext *c, const int16_t *buf0,
const int16_t *ubuf[2], const int16_t *vbuf[2],
const int16_t *abuf0, uint8_t *dest, int dstW,
int uvalpha, int y, enum PixelFormat target,
int hasAlpha)
{
const int16_t... | true | FFmpeg | 4a9f466b997e0c44d1e304a7a9c5d5de0b0868c7 | yuv2rgb_1_c_template(SwsContext *c, const int16_t *buf0,
const int16_t *ubuf[2], const int16_t *vbuf[2],
const int16_t *abuf0, uint8_t *dest, int dstW,
int uvalpha, int y, enum PixelFormat target,
int hasAlpha)
{
const int16_t... | {
"code": [
" A1 = (abuf0[i * 2 ] + 64) >> 7;",
" A2 = (abuf0[i * 2 + 1] + 64) >> 7;"
],
"line_no": [
43,
45
]
} | FUNC_0(SwsContext *VAR_0, const int16_t *VAR_1,
const int16_t *VAR_2[2], const int16_t *VAR_3[2],
const int16_t *VAR_4, uint8_t *VAR_5, int VAR_6,
int VAR_7, int VAR_8, enum PixelFormat VAR_9,
int VAR_10)
{
const int16_t *VAR_... | [
"FUNC_0(SwsContext *VAR_0, const int16_t *VAR_1,\nconst int16_t *VAR_2[2], const int16_t *VAR_3[2],\nconst int16_t *VAR_4, uint8_t *VAR_5, int VAR_6,\nint VAR_7, int VAR_8, enum PixelFormat VAR_9,\nint VAR_10)\n{",
"const int16_t *VAR_11 = VAR_2[0], *vbuf0 = VAR_3[0];",
"int VAR_12;",
"if (VAR_7 < 2048) {",
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5,
7,
9,
11
],
[
13
],
[
15
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33,
35,
37
],
[
41
],
[
43
],
[
45
],
[
47
],
[
51,
53
],
[... |
15,099 | void *qemu_vmalloc(size_t size)
{
/* FIXME: this is not exactly optimal solution since VirtualAlloc
has 64Kb granularity, but at least it guarantees us that the
memory is page aligned. */
if (!size) {
abort();
}
return oom_check(VirtualAlloc(NULL, size, MEM_COMMIT, PAGE_REA... | true | qemu | cd245a19329edfcd968b00d05ad92de7a0e2daa1 | void *qemu_vmalloc(size_t size)
{
if (!size) {
abort();
}
return oom_check(VirtualAlloc(NULL, size, MEM_COMMIT, PAGE_READWRITE));
}
| {
"code": [
" return oom_check(VirtualAlloc(NULL, size, MEM_COMMIT, PAGE_READWRITE));",
" return oom_check(VirtualAlloc(NULL, size, MEM_COMMIT, PAGE_READWRITE));"
],
"line_no": [
17,
17
]
} | void *FUNC_0(size_t VAR_0)
{
if (!VAR_0) {
abort();
}
return oom_check(VirtualAlloc(NULL, VAR_0, MEM_COMMIT, PAGE_READWRITE));
}
| [
"void *FUNC_0(size_t VAR_0)\n{",
"if (!VAR_0) {",
"abort();",
"}",
"return oom_check(VirtualAlloc(NULL, VAR_0, MEM_COMMIT, PAGE_READWRITE));",
"}"
] | [
0,
0,
0,
0,
1,
0
] | [
[
1,
3
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
]
] |
15,100 | static int real_seek(AVFormatContext *avf, int stream,
int64_t min_ts, int64_t ts, int64_t max_ts, int flags)
{
ConcatContext *cat = avf->priv_data;
int ret, left, right;
if (stream >= 0) {
if (stream >= avf->nb_streams)
return AVERROR(EINVAL);
resc... | false | FFmpeg | d608a27d9e28d24ab56acc4ea6bfb13b2802035c | static int real_seek(AVFormatContext *avf, int stream,
int64_t min_ts, int64_t ts, int64_t max_ts, int flags)
{
ConcatContext *cat = avf->priv_data;
int ret, left, right;
if (stream >= 0) {
if (stream >= avf->nb_streams)
return AVERROR(EINVAL);
resc... | {
"code": [],
"line_no": []
} | static int FUNC_0(AVFormatContext *VAR_0, int VAR_1,
int64_t VAR_2, int64_t VAR_3, int64_t VAR_4, int VAR_5)
{
ConcatContext *cat = VAR_0->priv_data;
int VAR_6, VAR_7, VAR_8;
if (VAR_1 >= 0) {
if (VAR_1 >= VAR_0->nb_streams)
return AVERROR(EINVAL);
... | [
"static int FUNC_0(AVFormatContext *VAR_0, int VAR_1,\nint64_t VAR_2, int64_t VAR_3, int64_t VAR_4, int VAR_5)\n{",
"ConcatContext *cat = VAR_0->priv_data;",
"int VAR_6, VAR_7, VAR_8;",
"if (VAR_1 >= 0) {",
"if (VAR_1 >= VAR_0->nb_streams)\nreturn AVERROR(EINVAL);",
"rescale_interval(VAR_0->streams[VAR_1]... | [
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
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35,
37
],
[
39,
41
],
[
43
],
[
47,
49
],
[
53
],
[
55,... |
15,101 | static void FUNC(dequant)(int16_t *coeffs, int16_t log2_size)
{
int shift = 15 - BIT_DEPTH - log2_size;
int x, y;
int size = 1 << log2_size;
if (shift > 0) {
int offset = 1 << (shift - 1);
for (y = 0; y < size; y++) {
for (x = 0; x < size; x++) {
*... | true | FFmpeg | 0c9ab5ef9c1ee852c80c859c9e07efe8730b57ed | static void FUNC(dequant)(int16_t *coeffs, int16_t log2_size)
{
int shift = 15 - BIT_DEPTH - log2_size;
int x, y;
int size = 1 << log2_size;
if (shift > 0) {
int offset = 1 << (shift - 1);
for (y = 0; y < size; y++) {
for (x = 0; x < size; x++) {
*... | {
"code": [
" *coeffs = *coeffs << -shift;"
],
"line_no": [
35
]
} | static void FUNC_0(dequant)(int16_t *coeffs, int16_t log2_size)
{
int VAR_0 = 15 - BIT_DEPTH - log2_size;
int VAR_1, VAR_2;
int VAR_3 = 1 << log2_size;
if (VAR_0 > 0) {
int VAR_4 = 1 << (VAR_0 - 1);
for (VAR_2 = 0; VAR_2 < VAR_3; VAR_2++) {
for (VAR_1 = 0; VAR_1 < ... | [
"static void FUNC_0(dequant)(int16_t *coeffs, int16_t log2_size)\n{",
"int VAR_0 = 15 - BIT_DEPTH - log2_size;",
"int VAR_1, VAR_2;",
"int VAR_3 = 1 << log2_size;",
"if (VAR_0 > 0) {",
"int VAR_4 = 1 << (VAR_0 - 1);",
"for (VAR_2 = 0; VAR_2 < VAR_3; VAR_2++) {",
"for (VAR_1 = 0; VAR_1 < VAR_3; VAR_1+... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
... |
15,102 | vpc_co_preadv(BlockDriverState *bs, uint64_t offset, uint64_t bytes,
QEMUIOVector *qiov, int flags)
{
BDRVVPCState *s = bs->opaque;
int ret;
int64_t image_offset;
int64_t n_bytes;
int64_t bytes_done = 0;
VHDFooter *footer = (VHDFooter *) s->footer_buf;
QEMUIOVector loc... | true | qemu | cfc87e00c22ab4ea0262c9771c803ed03d754001 | vpc_co_preadv(BlockDriverState *bs, uint64_t offset, uint64_t bytes,
QEMUIOVector *qiov, int flags)
{
BDRVVPCState *s = bs->opaque;
int ret;
int64_t image_offset;
int64_t n_bytes;
int64_t bytes_done = 0;
VHDFooter *footer = (VHDFooter *) s->footer_buf;
QEMUIOVector loc... | {
"code": [
" image_offset = get_image_offset(bs, offset, false);"
],
"line_no": [
39
]
} | FUNC_0(BlockDriverState *VAR_0, uint64_t VAR_1, uint64_t VAR_2,
QEMUIOVector *VAR_3, int VAR_4)
{
BDRVVPCState *s = VAR_0->opaque;
int VAR_5;
int64_t image_offset;
int64_t n_bytes;
int64_t bytes_done = 0;
VHDFooter *footer = (VHDFooter *) s->footer_buf;
QEMUIOVector lo... | [
"FUNC_0(BlockDriverState *VAR_0, uint64_t VAR_1, uint64_t VAR_2,\nQEMUIOVector *VAR_3, int VAR_4)\n{",
"BDRVVPCState *s = VAR_0->opaque;",
"int VAR_5;",
"int64_t image_offset;",
"int64_t n_bytes;",
"int64_t bytes_done = 0;",
"VHDFooter *footer = (VHDFooter *) s->footer_buf;",
"QEMUIOVector local_qiov;... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
23
],
[
25
],
[
27
],
[
31
],
[
33
],
[
37
],
[
39
],
[
41
],
[
45
],
[
47
],
[
49
],
[... |
15,103 | long do_rt_sigreturn(CPUMIPSState *env)
{
struct target_rt_sigframe *frame;
abi_ulong frame_addr;
sigset_t blocked;
frame_addr = env->active_tc.gpr[29];
trace_user_do_rt_sigreturn(env, frame_addr);
if (!lock_user_struct(VERIFY_READ, frame, frame_addr, 1)) {
goto badframe;
... | true | qemu | c599d4d6d6e9bfdb64e54c33a22cb26e3496b96d | long do_rt_sigreturn(CPUMIPSState *env)
{
struct target_rt_sigframe *frame;
abi_ulong frame_addr;
sigset_t blocked;
frame_addr = env->active_tc.gpr[29];
trace_user_do_rt_sigreturn(env, frame_addr);
if (!lock_user_struct(VERIFY_READ, frame, frame_addr, 1)) {
goto badframe;
... | {
"code": [
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" return 0;",
" ret... | long FUNC_0(CPUMIPSState *VAR_0)
{
struct target_rt_sigframe *VAR_1;
abi_ulong frame_addr;
sigset_t blocked;
frame_addr = VAR_0->active_tc.gpr[29];
trace_user_do_rt_sigreturn(VAR_0, frame_addr);
if (!lock_user_struct(VERIFY_READ, VAR_1, frame_addr, 1)) {
goto badframe;
}
... | [
"long FUNC_0(CPUMIPSState *VAR_0)\n{",
"struct target_rt_sigframe *VAR_1;",
"abi_ulong frame_addr;",
"sigset_t blocked;",
"frame_addr = VAR_0->active_tc.gpr[29];",
"trace_user_do_rt_sigreturn(VAR_0, frame_addr);",
"if (!lock_user_struct(VERIFY_READ, VAR_1, frame_addr, 1)) {",
"goto badframe;",
"}",
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
25
],
[
27
],
[
31
],
[
35,
37,
39,
41
],
[
45
],
[
47
],
[
53
],
[
55
],
[
59,
61
... |
15,104 | static CharDriverState *qemu_chr_open_socket(QemuOpts *opts)
{
CharDriverState *chr = NULL;
TCPCharDriver *s = NULL;
int fd = -1;
int is_listen;
int is_waitconnect;
int do_nodelay;
int is_unix;
int is_telnet;
is_listen = qemu_opt_get_bool(opts, "server", 0);
is_... | true | qemu | 233aa5c2d1cf4655ffe335025a68cf5454f87dad | static CharDriverState *qemu_chr_open_socket(QemuOpts *opts)
{
CharDriverState *chr = NULL;
TCPCharDriver *s = NULL;
int fd = -1;
int is_listen;
int is_waitconnect;
int do_nodelay;
int is_unix;
int is_telnet;
is_listen = qemu_opt_get_bool(opts, "server", 0);
is_... | {
"code": [
" } else {",
" fd = inet_connect_opts(opts, true, NULL, NULL);"
],
"line_no": [
57,
65
]
} | static CharDriverState *FUNC_0(QemuOpts *opts)
{
CharDriverState *chr = NULL;
TCPCharDriver *s = NULL;
int VAR_0 = -1;
int VAR_1;
int VAR_2;
int VAR_3;
int VAR_4;
int VAR_5;
VAR_1 = qemu_opt_get_bool(opts, "server", 0);
VAR_2 = qemu_opt_get_bool(opts, "wait", 1)... | [
"static CharDriverState *FUNC_0(QemuOpts *opts)\n{",
"CharDriverState *chr = NULL;",
"TCPCharDriver *s = NULL;",
"int VAR_0 = -1;",
"int VAR_1;",
"int VAR_2;",
"int VAR_3;",
"int VAR_4;",
"int VAR_5;",
"VAR_1 = qemu_opt_get_bool(opts, \"server\", 0);",
"VAR_2 = qemu_opt_get_bool(opts, \"wai... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
39
],
[
41
],
[
45
],
[
47
],
[... |
15,105 | void qtest_qmpv_discard_response(QTestState *s, const char *fmt, va_list ap)
{
bool has_reply = false;
int nesting = 0;
/* Send QMP request */
socket_sendf(s->qmp_fd, fmt, ap);
/* Receive reply */
while (!has_reply || nesting > 0) {
ssize_t len;
char c;
le... | true | qemu | 0c460dac03e7919079525d8e24ef2c4c607c219d | void qtest_qmpv_discard_response(QTestState *s, const char *fmt, va_list ap)
{
bool has_reply = false;
int nesting = 0;
socket_sendf(s->qmp_fd, fmt, ap);
while (!has_reply || nesting > 0) {
ssize_t len;
char c;
len = read(s->qmp_fd, &c, 1);
if (... | {
"code": [
"void qtest_qmpv_discard_response(QTestState *s, const char *fmt, va_list ap)",
" bool has_reply = false;",
" int nesting = 0;",
" while (!has_reply || nesting > 0) {",
" switch (c) {",
" case '{':",
" nesting++;",
" has_reply = ... | void FUNC_0(QTestState *VAR_0, const char *VAR_1, va_list VAR_2)
{
bool has_reply = false;
int VAR_3 = 0;
socket_sendf(VAR_0->qmp_fd, VAR_1, VAR_2);
while (!has_reply || VAR_3 > 0) {
ssize_t len;
char VAR_4;
len = read(VAR_0->qmp_fd, &VAR_4, 1);
... | [
"void FUNC_0(QTestState *VAR_0, const char *VAR_1, va_list VAR_2)\n{",
"bool has_reply = false;",
"int VAR_3 = 0;",
"socket_sendf(VAR_0->qmp_fd, VAR_1, VAR_2);",
"while (!has_reply || VAR_3 > 0) {",
"ssize_t len;",
"char VAR_4;",
"len = read(VAR_0->qmp_fd, &VAR_4, 1);",
"if (len == -1 && errno == EI... | [
1,
1,
1,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
13
],
[
19
],
[
21
],
[
23
],
[
27
],
[
29
],
[
31
],
[
33
],
[
37
],
[
39
],
[
41
],
[
43
],
[
47
],
[
49
],
[
51
],
[
53
],
[
55... |
15,107 | static av_noinline void FUNC(hl_decode_mb_444)(H264Context *h)
{
const int mb_x = h->mb_x;
const int mb_y = h->mb_y;
const int mb_xy = h->mb_xy;
const int mb_type = h->cur_pic.f.mb_type[mb_xy];
uint8_t *dest[3];
int linesize;
int i, j, p;
int *block_offset = &h->block_of... | false | FFmpeg | 1acd7d594c15aa491729c837ad3519d3469e620a | static av_noinline void FUNC(hl_decode_mb_444)(H264Context *h)
{
const int mb_x = h->mb_x;
const int mb_y = h->mb_y;
const int mb_xy = h->mb_xy;
const int mb_type = h->cur_pic.f.mb_type[mb_xy];
uint8_t *dest[3];
int linesize;
int i, j, p;
int *block_offset = &h->block_of... | {
"code": [],
"line_no": []
} | static av_noinline void FUNC_0(hl_decode_mb_444)(H264Context *h)
{
const int VAR_0 = h->VAR_0;
const int VAR_1 = h->VAR_1;
const int VAR_2 = h->VAR_2;
const int VAR_3 = h->cur_pic.f.VAR_3[VAR_2];
uint8_t *dest[3];
int VAR_4;
int VAR_5, VAR_6, VAR_7;
int *VAR_8 = &h->VAR_... | [
"static av_noinline void FUNC_0(hl_decode_mb_444)(H264Context *h)\n{",
"const int VAR_0 = h->VAR_0;",
"const int VAR_1 = h->VAR_1;",
"const int VAR_2 = h->VAR_2;",
"const int VAR_3 = h->cur_pic.f.VAR_3[VAR_2];",
"uint8_t *dest[3];",
"int VAR_4;",
"int VAR_5, VAR_6, VAR_7;",
"int *VAR_8 = &h-... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
41
],
[
45
],
[
47
],
[
49
... |
15,109 | static void msvideo1_decode_8bit(Msvideo1Context *s)
{
int block_ptr, pixel_ptr;
int total_blocks;
int pixel_x, pixel_y; /* pixel width and height iterators */
int block_x, block_y; /* block width and height iterators */
int blocks_wide, blocks_high; /* width and height in 4x4 blocks */
... | false | FFmpeg | 875efafac8afe22971c87fc7dfee83d27364ab50 | static void msvideo1_decode_8bit(Msvideo1Context *s)
{
int block_ptr, pixel_ptr;
int total_blocks;
int pixel_x, pixel_y;
int block_x, block_y;
int blocks_wide, blocks_high;
int block_inc;
int row_dec;
int stream_ptr;
unsigned char byte_a, byte_b;
unsigned... | {
"code": [],
"line_no": []
} | static void FUNC_0(Msvideo1Context *VAR_0)
{
int VAR_1, VAR_2;
int VAR_3;
int VAR_4, VAR_5;
int VAR_6, VAR_7;
int VAR_8, VAR_9;
int VAR_10;
int VAR_11;
int VAR_12;
unsigned char VAR_13, VAR_14;
unsigned short VAR_15;
int VAR_16;
unsigned char VA... | [
"static void FUNC_0(Msvideo1Context *VAR_0)\n{",
"int VAR_1, VAR_2;",
"int VAR_3;",
"int VAR_4, VAR_5;",
"int VAR_6, VAR_7;",
"int VAR_8, VAR_9;",
"int VAR_10;",
"int VAR_11;",
"int VAR_12;",
"unsigned char VAR_13, VAR_14;",
"unsigned short VAR_15;",
"int VAR_16;",
"unsigned char VAR_17[8];"... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
41
],
[
43
],
[
45
],
[
47
... |
15,110 | static int lrc_read_header(AVFormatContext *s)
{
LRCContext *lrc = s->priv_data;
AVBPrint line;
AVStream *st;
st = avformat_new_stream(s, NULL);
if(!st) {
return AVERROR(ENOMEM);
}
avpriv_set_pts_info(st, 64, 1, 1000);
lrc->ts_offset = 0;
st->codecpar->codec_type... | true | FFmpeg | ef5994e09d07ace62a672fcdc84761231288edad | static int lrc_read_header(AVFormatContext *s)
{
LRCContext *lrc = s->priv_data;
AVBPrint line;
AVStream *st;
st = avformat_new_stream(s, NULL);
if(!st) {
return AVERROR(ENOMEM);
}
avpriv_set_pts_info(st, 64, 1, 1000);
lrc->ts_offset = 0;
st->codecpar->codec_type... | {
"code": [],
"line_no": []
} | static int FUNC_0(AVFormatContext *VAR_0)
{
LRCContext *lrc = VAR_0->priv_data;
AVBPrint line;
AVStream *st;
st = avformat_new_stream(VAR_0, NULL);
if(!st) {
return AVERROR(ENOMEM);
}
avpriv_set_pts_info(st, 64, 1, 1000);
lrc->ts_offset = 0;
st->codecpar->codec_t... | [
"static int FUNC_0(AVFormatContext *VAR_0)\n{",
"LRCContext *lrc = VAR_0->priv_data;",
"AVBPrint line;",
"AVStream *st;",
"st = avformat_new_stream(VAR_0, NULL);",
"if(!st) {",
"return AVERROR(ENOMEM);",
"}",
"avpriv_set_pts_info(st, 64, 1, 1000);",
"lrc->ts_offset = 0;",
"st->codecpar->codec_ty... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
... |
15,111 | static int asf_write_header1(AVFormatContext *s, int64_t file_size,
int64_t data_chunk_size)
{
ASFContext *asf = s->priv_data;
AVIOContext *pb = s->pb;
AVDictionaryEntry *tags[5];
int header_size, n, extra_size, extra_size2, wav_extra_size, file_time;
int has_titl... | true | FFmpeg | ff3db937ef3aa30046a3936146f86ad48ee2ff90 | static int asf_write_header1(AVFormatContext *s, int64_t file_size,
int64_t data_chunk_size)
{
ASFContext *asf = s->priv_data;
AVIOContext *pb = s->pb;
AVDictionaryEntry *tags[5];
int header_size, n, extra_size, extra_size2, wav_extra_size, file_time;
int has_titl... | {
"code": [
" int64_t duration;",
" duration = asf->duration + PREROLL_TIME * 10000;",
" int64_t duration;"
],
"line_no": [
25,
45,
25
]
} | static int FUNC_0(AVFormatContext *VAR_0, int64_t VAR_1,
int64_t VAR_2)
{
ASFContext *asf = VAR_0->priv_data;
AVIOContext *pb = VAR_0->pb;
AVDictionaryEntry *tags[5];
int VAR_3, VAR_4, VAR_5, VAR_6, VAR_7, VAR_8;
int VAR_9;
int VAR_10;
AVCodecParameters ... | [
"static int FUNC_0(AVFormatContext *VAR_0, int64_t VAR_1,\nint64_t VAR_2)\n{",
"ASFContext *asf = VAR_0->priv_data;",
"AVIOContext *pb = VAR_0->pb;",
"AVDictionaryEntry *tags[5];",
"int VAR_3, VAR_4, VAR_5, VAR_6, VAR_7, VAR_8;",
"int VAR_9;",
"int VAR_10;",
"AVCodecParameters *par;",
"int64_t heade... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
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... | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
29
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
45
],
[
47
],
[... |
15,112 | void qemu_aio_wait(void)
{
sigset_t set;
int nb_sigs;
#if !defined(QEMU_IMG) && !defined(QEMU_NBD)
if (qemu_bh_poll())
return;
#endif
sigemptyset(&set);
sigaddset(&set, aio_sig_num);
sigwait(&set, &nb_sigs);
qemu_aio_poll();
}
| true | qemu | baf35cb90204d75404892aa4e52628ae7a00669b | void qemu_aio_wait(void)
{
sigset_t set;
int nb_sigs;
#if !defined(QEMU_IMG) && !defined(QEMU_NBD)
if (qemu_bh_poll())
return;
#endif
sigemptyset(&set);
sigaddset(&set, aio_sig_num);
sigwait(&set, &nb_sigs);
qemu_aio_poll();
}
| {
"code": [
"#if !defined(QEMU_IMG) && !defined(QEMU_NBD)",
"#endif",
"#endif",
"#endif",
" qemu_aio_poll();",
" sigset_t set;",
" sigemptyset(&set);",
" sigaddset(&set, aio_sig_num);",
" sigset_t set;",
" int nb_sigs;",
" sigemptyset(&set);",
" ... | void FUNC_0(void)
{
sigset_t set;
int VAR_0;
#if !defined(QEMU_IMG) && !defined(QEMU_NBD)
if (qemu_bh_poll())
return;
#endif
sigemptyset(&set);
sigaddset(&set, aio_sig_num);
sigwait(&set, &VAR_0);
qemu_aio_poll();
}
| [
"void FUNC_0(void)\n{",
"sigset_t set;",
"int VAR_0;",
"#if !defined(QEMU_IMG) && !defined(QEMU_NBD)\nif (qemu_bh_poll())\nreturn;",
"#endif\nsigemptyset(&set);",
"sigaddset(&set, aio_sig_num);",
"sigwait(&set, &VAR_0);",
"qemu_aio_poll();",
"}"
] | [
0,
1,
1,
1,
1,
1,
1,
1,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11,
13,
15
],
[
17,
19
],
[
21
],
[
23
],
[
25
],
[
27
]
] |
15,113 | static void config_error(Monitor *mon, const char *fmt, ...)
{
va_list ap;
va_start(ap, fmt);
if (mon) {
monitor_vprintf(mon, fmt, ap);
} else {
fprintf(stderr, "qemu: ");
vfprintf(stderr, fmt, ap);
exit(1);
}
va_end(ap);
}
| true | qemu | 0752706de257b38763006ff5bb6b39a97e669ba2 | static void config_error(Monitor *mon, const char *fmt, ...)
{
va_list ap;
va_start(ap, fmt);
if (mon) {
monitor_vprintf(mon, fmt, ap);
} else {
fprintf(stderr, "qemu: ");
vfprintf(stderr, fmt, ap);
exit(1);
}
va_end(ap);
}
| {
"code": [
" exit(1);",
" exit(1);"
],
"line_no": [
21,
21
]
} | static void FUNC_0(Monitor *VAR_0, const char *VAR_1, ...)
{
va_list ap;
va_start(ap, VAR_1);
if (VAR_0) {
monitor_vprintf(VAR_0, VAR_1, ap);
} else {
fprintf(stderr, "qemu: ");
vfprintf(stderr, VAR_1, ap);
exit(1);
}
va_end(ap);
}
| [
"static void FUNC_0(Monitor *VAR_0, const char *VAR_1, ...)\n{",
"va_list ap;",
"va_start(ap, VAR_1);",
"if (VAR_0) {",
"monitor_vprintf(VAR_0, VAR_1, ap);",
"} else {",
"fprintf(stderr, \"qemu: \");",
"vfprintf(stderr, VAR_1, ap);",
"exit(1);",
"}",
"va_end(ap);",
"}"
] | [
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
]
] |
15,114 | static int coroutine_fn raw_co_writev(BlockDriverState *bs, int64_t sector_num,
int nb_sectors, QEMUIOVector *qiov)
{
BLKDBG_EVENT(bs->file, BLKDBG_WRITE_AIO);
return bdrv_co_writev(bs->file, sector_num, nb_sectors, qiov);
}
| true | qemu | 38f3ef574b48afc507c6f636ae4393fd36bda072 | static int coroutine_fn raw_co_writev(BlockDriverState *bs, int64_t sector_num,
int nb_sectors, QEMUIOVector *qiov)
{
BLKDBG_EVENT(bs->file, BLKDBG_WRITE_AIO);
return bdrv_co_writev(bs->file, sector_num, nb_sectors, qiov);
}
| {
"code": [
" return bdrv_co_writev(bs->file, sector_num, nb_sectors, qiov);"
],
"line_no": [
9
]
} | static int VAR_0 raw_co_writev(BlockDriverState *bs, int64_t sector_num,
int nb_sectors, QEMUIOVector *qiov)
{
BLKDBG_EVENT(bs->file, BLKDBG_WRITE_AIO);
return bdrv_co_writev(bs->file, sector_num, nb_sectors, qiov);
}
| [
"static int VAR_0 raw_co_writev(BlockDriverState *bs, int64_t sector_num,\nint nb_sectors, QEMUIOVector *qiov)\n{",
"BLKDBG_EVENT(bs->file, BLKDBG_WRITE_AIO);",
"return bdrv_co_writev(bs->file, sector_num, nb_sectors, qiov);",
"}"
] | [
0,
0,
1,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
]
] |
15,117 | void g_free(void *ptr)
{
/* FIXME: We should unmark the reserved pages here. However this gets
complicated when one target page spans multiple host pages, so we
don't bother. */
size_t *p;
p = (size_t *)((char *)ptr - 16);
munmap(p, *p);
}
| true | qemu | b7b5233ad7fdd9985bb6d05b7919f3a20723ff2c | void g_free(void *ptr)
{
size_t *p;
p = (size_t *)((char *)ptr - 16);
munmap(p, *p);
}
| {
"code": [
"void g_free(void *ptr)",
" size_t *p;",
" p = (size_t *)((char *)ptr - 16);",
" munmap(p, *p);"
],
"line_no": [
1,
11,
13,
15
]
} | void FUNC_0(void *VAR_0)
{
size_t *p;
p = (size_t *)((char *)VAR_0 - 16);
munmap(p, *p);
}
| [
"void FUNC_0(void *VAR_0)\n{",
"size_t *p;",
"p = (size_t *)((char *)VAR_0 - 16);",
"munmap(p, *p);",
"}"
] | [
1,
1,
1,
1,
0
] | [
[
1,
3
],
[
11
],
[
13
],
[
15
],
[
17
]
] |
15,118 | static SCSIGenericReq *scsi_new_request(SCSIDevice *d, uint32_t tag, uint32_t lun)
{
SCSIRequest *req;
req = scsi_req_alloc(sizeof(SCSIGenericReq), d, tag, lun);
return DO_UPCAST(SCSIGenericReq, req, req);
}
| true | qemu | 5c6c0e513600ba57c3e73b7151d3c0664438f7b5 | static SCSIGenericReq *scsi_new_request(SCSIDevice *d, uint32_t tag, uint32_t lun)
{
SCSIRequest *req;
req = scsi_req_alloc(sizeof(SCSIGenericReq), d, tag, lun);
return DO_UPCAST(SCSIGenericReq, req, req);
}
| {
"code": [
" SCSIRequest *req;",
"static SCSIGenericReq *scsi_new_request(SCSIDevice *d, uint32_t tag, uint32_t lun)",
" return DO_UPCAST(SCSIGenericReq, req, req);"
],
"line_no": [
5,
1,
11
]
} | static SCSIGenericReq *FUNC_0(SCSIDevice *d, uint32_t tag, uint32_t lun)
{
SCSIRequest *req;
req = scsi_req_alloc(sizeof(SCSIGenericReq), d, tag, lun);
return DO_UPCAST(SCSIGenericReq, req, req);
}
| [
"static SCSIGenericReq *FUNC_0(SCSIDevice *d, uint32_t tag, uint32_t lun)\n{",
"SCSIRequest *req;",
"req = scsi_req_alloc(sizeof(SCSIGenericReq), d, tag, lun);",
"return DO_UPCAST(SCSIGenericReq, req, req);",
"}"
] | [
1,
1,
0,
1,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
],
[
13
]
] |
15,119 | static void test_reconnect(void)
{
gchar *path = g_strdup_printf("/%s/vhost-user/reconnect/subprocess",
qtest_get_arch());
g_test_trap_subprocess(path, 0, 0);
g_test_trap_assert_passed();
} | true | qemu | 69179fe2fc0b91f68699012ba72d329e74ff629e | static void test_reconnect(void)
{
gchar *path = g_strdup_printf("/%s/vhost-user/reconnect/subprocess",
qtest_get_arch());
g_test_trap_subprocess(path, 0, 0);
g_test_trap_assert_passed();
} | {
"code": [],
"line_no": []
} | static void FUNC_0(void)
{
gchar *path = g_strdup_printf("/%s/vhost-user/reconnect/subprocess",
qtest_get_arch());
g_test_trap_subprocess(path, 0, 0);
g_test_trap_assert_passed();
} | [
"static void FUNC_0(void)\n{",
"gchar *path = g_strdup_printf(\"/%s/vhost-user/reconnect/subprocess\",\nqtest_get_arch());",
"g_test_trap_subprocess(path, 0, 0);",
"g_test_trap_assert_passed();",
"}"
] | [
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5,
7
],
[
9
],
[
11
],
[
14
]
] |
15,120 | int64_t qdict_get_try_int(const QDict *qdict, const char *key,
int64_t def_value)
{
QObject *obj;
obj = qdict_get(qdict, key);
if (!obj || qobject_type(obj) != QTYPE_QINT)
return def_value;
return qint_get_int(qobject_to_qint(obj));
}
| true | qemu | fcf73f66a67f5e58c18216f8c8651e38cf4d90af | int64_t qdict_get_try_int(const QDict *qdict, const char *key,
int64_t def_value)
{
QObject *obj;
obj = qdict_get(qdict, key);
if (!obj || qobject_type(obj) != QTYPE_QINT)
return def_value;
return qint_get_int(qobject_to_qint(obj));
}
| {
"code": [
" return qint_get_int(qobject_to_qint(obj));",
" QObject *obj;",
" obj = qdict_get(qdict, key);",
" if (!obj || qobject_type(obj) != QTYPE_QINT)",
" return def_value;",
" return qint_get_int(qobject_to_qint(obj));"
],
"line_no": [
19,
7,
11,
... | int64_t FUNC_0(const QDict *qdict, const char *key,
int64_t def_value)
{
QObject *obj;
obj = qdict_get(qdict, key);
if (!obj || qobject_type(obj) != QTYPE_QINT)
return def_value;
return qint_get_int(qobject_to_qint(obj));
}
| [
"int64_t FUNC_0(const QDict *qdict, const char *key,\nint64_t def_value)\n{",
"QObject *obj;",
"obj = qdict_get(qdict, key);",
"if (!obj || qobject_type(obj) != QTYPE_QINT)\nreturn def_value;",
"return qint_get_int(qobject_to_qint(obj));",
"}"
] | [
0,
1,
1,
1,
1,
0
] | [
[
1,
3,
5
],
[
7
],
[
11
],
[
13,
15
],
[
19
],
[
21
]
] |
15,121 | static inline void RENAME(bgr24ToY)(uint8_t *dst, uint8_t *src, int width)
{
#ifdef HAVE_MMX
asm volatile(
"mov %2, %%"REG_a" \n\t"
"movq "MANGLE(bgr2YCoeff)", %%mm6 \n\t"
"movq "MANGLE(w1111)", %%mm5 \n\t"
"pxor %%mm7, %%mm7 \n\t"
"lea (%%"REG_a", %%"REG_a", 2), %%"REG_b"\n\t"
".balign 16 \... | true | FFmpeg | 7f526efd17973ec6d2204f7a47b6923e2be31363 | static inline void RENAME(bgr24ToY)(uint8_t *dst, uint8_t *src, int width)
{
#ifdef HAVE_MMX
asm volatile(
"mov %2, %%"REG_a" \n\t"
"movq "MANGLE(bgr2YCoeff)", %%mm6 \n\t"
"movq "MANGLE(w1111)", %%mm5 \n\t"
"pxor %%mm7, %%mm7 \n\t"
"lea (%%"REG_a", %%"REG_a", 2), %%"REG_b"\n\t"
".balign 16 \... | {
"code": [
"static inline void RENAME(bgr24ToY)(uint8_t *dst, uint8_t *src, int width)",
"\t\t: : \"r\" (src+width*3), \"r\" (dst+width), \"g\" ((long)-width)"
],
"line_no": [
1,
139
]
} | static inline void FUNC_0(bgr24ToY)(uint8_t *dst, uint8_t *src, int width)
{
#ifdef HAVE_MMX
asm volatile(
"mov %2, %%"REG_a" \n\t"
"movq "MANGLE(bgr2YCoeff)", %%mm6 \n\t"
"movq "MANGLE(w1111)", %%mm5 \n\t"
"pxor %%mm7, %%mm7 \n\t"
"lea (%%"REG_a", %%"REG_a", 2), %%"REG_b"\n\t"
".balign 16 \... | [
"static inline void FUNC_0(bgr24ToY)(uint8_t *dst, uint8_t *src, int width)\n{",
"#ifdef HAVE_MMX\nasm volatile(\n\"mov %2, %%\"REG_a\"\t\t\\n\\t\"\n\"movq \"MANGLE(bgr2YCoeff)\", %%mm6\t\t\\n\\t\"\n\"movq \"MANGLE(w1111)\", %%mm5\t\t\\n\\t\"\n\"pxor %%mm7, %%mm7\t\t\\n\\t\"\n\"lea (%%\"REG_a\", %%\"REG_a\", 2), ... | [
1,
1,
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,
45,
47,
49,
51,
53,
55,
57,
59,
61,
63,
65,
67,
69,
71,
75,
77,
79,... |
15,122 | void dsputil_init_armv4l(void)
{
// ff_idct = j_rev_dct_ARM;
}
| false | FFmpeg | 83f238cbf0c038245d2b2dffa5beb0916e7c36d2 | void dsputil_init_armv4l(void)
{
}
| {
"code": [],
"line_no": []
} | void FUNC_0(void)
{
}
| [
"void FUNC_0(void)\n{",
"}"
] | [
0,
0
] | [
[
1,
3
],
[
7
]
] |
15,123 | static void RENAME(resample_one)(DELEM *dst, const DELEM *src,
int dst_size, int64_t index2, int64_t incr)
{
int dst_index;
for (dst_index = 0; dst_index < dst_size; dst_index++) {
dst[dst_index] = src[index2 >> 32];
index2 += incr;
}
}
| false | FFmpeg | 857cd1f33bcf86005529af2a77f861f884327be5 | static void RENAME(resample_one)(DELEM *dst, const DELEM *src,
int dst_size, int64_t index2, int64_t incr)
{
int dst_index;
for (dst_index = 0; dst_index < dst_size; dst_index++) {
dst[dst_index] = src[index2 >> 32];
index2 += incr;
}
}
| {
"code": [],
"line_no": []
} | static void FUNC_0(resample_one)(DELEM *dst, const DELEM *src,
int dst_size, int64_t index2, int64_t incr)
{
int VAR_0;
for (VAR_0 = 0; VAR_0 < dst_size; VAR_0++) {
dst[VAR_0] = src[index2 >> 32];
index2 += incr;
}
}
| [
"static void FUNC_0(resample_one)(DELEM *dst, const DELEM *src,\nint dst_size, int64_t index2, int64_t incr)\n{",
"int VAR_0;",
"for (VAR_0 = 0; VAR_0 < dst_size; VAR_0++) {",
"dst[VAR_0] = src[index2 >> 32];",
"index2 += incr;",
"}",
"}"
] | [
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
]
] |
15,126 | static int qemu_gluster_create(const char *filename,
QEMUOptionParameter *options, Error **errp)
{
struct glfs *glfs;
struct glfs_fd *fd;
int ret = 0;
int prealloc = 0;
int64_t total_size = 0;
GlusterConf *gconf = g_malloc0(sizeof(GlusterConf));
glfs = qemu_gluster_init(gc... | true | qemu | 4557117d9eed8cadc360aec23b42fc39a7011864 | static int qemu_gluster_create(const char *filename,
QEMUOptionParameter *options, Error **errp)
{
struct glfs *glfs;
struct glfs_fd *fd;
int ret = 0;
int prealloc = 0;
int64_t total_size = 0;
GlusterConf *gconf = g_malloc0(sizeof(GlusterConf));
glfs = qemu_gluster_init(gc... | {
"code": [
" ret = -EINVAL;"
],
"line_no": [
25
]
} | static int FUNC_0(const char *VAR_0,
QEMUOptionParameter *VAR_1, Error **VAR_2)
{
struct VAR_3 *VAR_3;
struct glfs_fd *VAR_4;
int VAR_5 = 0;
int VAR_6 = 0;
int64_t total_size = 0;
GlusterConf *gconf = g_malloc0(sizeof(GlusterConf));
VAR_3 = qemu_gluster_init(gconf, VAR_0, ... | [
"static int FUNC_0(const char *VAR_0,\nQEMUOptionParameter *VAR_1, Error **VAR_2)\n{",
"struct VAR_3 *VAR_3;",
"struct glfs_fd *VAR_4;",
"int VAR_5 = 0;",
"int VAR_6 = 0;",
"int64_t total_size = 0;",
"GlusterConf *gconf = g_malloc0(sizeof(GlusterConf));",
"VAR_3 = qemu_gluster_init(gconf, VAR_0, VAR_2... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[... |
15,127 | void OPPROTO op_subfme (void)
{
T0 = ~T0 + xer_ca - 1;
if (likely((uint32_t)T0 != (uint32_t)-1))
xer_ca = 1;
RETURN();
}
| true | qemu | c3e10c7b4377c1cbc0a4fbc12312c2cf41c0cda7 | void OPPROTO op_subfme (void)
{
T0 = ~T0 + xer_ca - 1;
if (likely((uint32_t)T0 != (uint32_t)-1))
xer_ca = 1;
RETURN();
}
| {
"code": [
" RETURN();",
" RETURN();",
" if (likely((uint32_t)T0 != (uint32_t)-1))",
" RETURN();"
],
"line_no": [
11,
11,
7,
11
]
} | void VAR_0 op_subfme (void)
{
T0 = ~T0 + xer_ca - 1;
if (likely((uint32_t)T0 != (uint32_t)-1))
xer_ca = 1;
RETURN();
}
| [
"void VAR_0 op_subfme (void)\n{",
"T0 = ~T0 + xer_ca - 1;",
"if (likely((uint32_t)T0 != (uint32_t)-1))\nxer_ca = 1;",
"RETURN();",
"}"
] | [
0,
0,
1,
1,
0
] | [
[
1,
3
],
[
5
],
[
7,
9
],
[
11
],
[
13
]
] |
15,128 | int nbd_client_co_pwrite_zeroes(BlockDriverState *bs, int64_t offset,
int count, BdrvRequestFlags flags)
{
ssize_t ret;
NBDClientSession *client = nbd_get_client_session(bs);
NBDRequest request = {
.type = NBD_CMD_WRITE_ZEROES,
.from = offset,
... | true | qemu | 6bdcc018a6ed760b9dfe43539124e420aed83092 | int nbd_client_co_pwrite_zeroes(BlockDriverState *bs, int64_t offset,
int count, BdrvRequestFlags flags)
{
ssize_t ret;
NBDClientSession *client = nbd_get_client_session(bs);
NBDRequest request = {
.type = NBD_CMD_WRITE_ZEROES,
.from = offset,
... | {
"code": [
" nbd_coroutine_start(client, &request);",
" nbd_coroutine_start(client, &request);",
" nbd_coroutine_start(client, &request);",
" nbd_coroutine_start(client, &request);",
" nbd_coroutine_start(client, &request);"
],
"line_no": [
49,
49,
49,
49,
4... | int FUNC_0(BlockDriverState *VAR_0, int64_t VAR_1,
int VAR_2, BdrvRequestFlags VAR_3)
{
ssize_t ret;
NBDClientSession *client = nbd_get_client_session(VAR_0);
NBDRequest request = {
.type = NBD_CMD_WRITE_ZEROES,
.from = VAR_1,
.len = VAR_2,
... | [
"int FUNC_0(BlockDriverState *VAR_0, int64_t VAR_1,\nint VAR_2, BdrvRequestFlags VAR_3)\n{",
"ssize_t ret;",
"NBDClientSession *client = nbd_get_client_session(VAR_0);",
"NBDRequest request = {",
".type = NBD_CMD_WRITE_ZEROES,\n.from = VAR_1,\n.len = VAR_2,\n};",
"NBDReply reply;",
"if (!(client->nbdfla... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
13,
15,
17,
19
],
[
21
],
[
25
],
[
27
],
[
29
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[
49
],
[
51
... |
15,129 | static void usbredir_control_packet(void *priv, uint32_t id,
struct usb_redir_control_packet_header *control_packet,
uint8_t *data, int data_len)
{
USBRedirDevice *dev = priv;
int len = control_packet->length;
AsyncURB *aurb;
DPRINTF("ctrl-in status %d len %d id %u\n", control_packet->s... | true | qemu | 4f4321c11ff6e98583846bfd6f0e81954924b003 | static void usbredir_control_packet(void *priv, uint32_t id,
struct usb_redir_control_packet_header *control_packet,
uint8_t *data, int data_len)
{
USBRedirDevice *dev = priv;
int len = control_packet->length;
AsyncURB *aurb;
DPRINTF("ctrl-in status %d len %d id %u\n", control_packet->s... | {
"code": [
" aurb->packet->len = len;",
" aurb->packet->len = len;"
],
"line_no": [
75,
75
]
} | static void FUNC_0(void *VAR_0, uint32_t VAR_1,
struct usb_redir_control_packet_header *VAR_2,
uint8_t *VAR_3, int VAR_4)
{
USBRedirDevice *dev = VAR_0;
int VAR_5 = VAR_2->length;
AsyncURB *aurb;
DPRINTF("ctrl-in status %d VAR_5 %d VAR_1 %u\n", VAR_2->status,
VAR_5, VAR_1);... | [
"static void FUNC_0(void *VAR_0, uint32_t VAR_1,\nstruct usb_redir_control_packet_header *VAR_2,\nuint8_t *VAR_3, int VAR_4)\n{",
"USBRedirDevice *dev = VAR_0;",
"int VAR_5 = VAR_2->length;",
"AsyncURB *aurb;",
"DPRINTF(\"ctrl-in status %d VAR_5 %d VAR_1 %u\\n\", VAR_2->status,\nVAR_5, VAR_1);",
"aurb = 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,
0,
0,
0,
0,
0
] | [
[
1,
3,
5,
7
],
[
9
],
[
11
],
[
13
],
[
17,
19
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
35
],
[
37
],
[
39,
41
],
[
43
],
[
45
],
[
47
],
[
51
],
[
53
... |
15,131 | int ff_init_buffer_info(AVCodecContext *avctx, AVFrame *frame)
{
if (avctx->internal->pkt) {
frame->pkt_pts = avctx->internal->pkt->pts;
av_frame_set_pkt_pos (frame, avctx->internal->pkt->pos);
av_frame_set_pkt_duration(frame, avctx->internal->pkt->duration);
av_frame_set_p... | false | FFmpeg | e5c7229999182ad1cef13b9eca050dba7a5a08da | int ff_init_buffer_info(AVCodecContext *avctx, AVFrame *frame)
{
if (avctx->internal->pkt) {
frame->pkt_pts = avctx->internal->pkt->pts;
av_frame_set_pkt_pos (frame, avctx->internal->pkt->pos);
av_frame_set_pkt_duration(frame, avctx->internal->pkt->duration);
av_frame_set_p... | {
"code": [],
"line_no": []
} | int FUNC_0(AVCodecContext *VAR_0, AVFrame *VAR_1)
{
if (VAR_0->internal->pkt) {
VAR_1->pkt_pts = VAR_0->internal->pkt->pts;
av_frame_set_pkt_pos (VAR_1, VAR_0->internal->pkt->pos);
av_frame_set_pkt_duration(VAR_1, VAR_0->internal->pkt->duration);
av_frame_set_pkt_size (V... | [
"int FUNC_0(AVCodecContext *VAR_0, AVFrame *VAR_1)\n{",
"if (VAR_0->internal->pkt) {",
"VAR_1->pkt_pts = VAR_0->internal->pkt->pts;",
"av_frame_set_pkt_pos (VAR_1, VAR_0->internal->pkt->pos);",
"av_frame_set_pkt_duration(VAR_1, VAR_0->internal->pkt->duration);",
"av_frame_set_pkt_size (VAR_1, 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
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
31
],
[
33,
35,
37
],
[
39,
41
],
[
43,
45
],
[
47,... |
15,135 | AVFilterContext *avfilter_open(AVFilter *filter, char *inst_name)
{
AVFilterContext *ret = av_malloc(sizeof(AVFilterContext));
ret->av_class = av_mallocz(sizeof(AVClass));
ret->av_class->item_name = filter_name;
ret->filter = filter;
ret->name = inst_name ? av_strdup(inst_name) : NULL;... | true | FFmpeg | 8f618f4c048e3579b62768665c255b89bd99b89f | AVFilterContext *avfilter_open(AVFilter *filter, char *inst_name)
{
AVFilterContext *ret = av_malloc(sizeof(AVFilterContext));
ret->av_class = av_mallocz(sizeof(AVClass));
ret->av_class->item_name = filter_name;
ret->filter = filter;
ret->name = inst_name ? av_strdup(inst_name) : NULL;... | {
"code": [
" AVFilterContext *ret = av_malloc(sizeof(AVFilterContext));"
],
"line_no": [
5
]
} | AVFilterContext *FUNC_0(AVFilter *filter, char *inst_name)
{
AVFilterContext *ret = av_malloc(sizeof(AVFilterContext));
ret->av_class = av_mallocz(sizeof(AVClass));
ret->av_class->item_name = filter_name;
ret->filter = filter;
ret->name = inst_name ? av_strdup(inst_name) : NULL;
r... | [
"AVFilterContext *FUNC_0(AVFilter *filter, char *inst_name)\n{",
"AVFilterContext *ret = av_malloc(sizeof(AVFilterContext));",
"ret->av_class = av_mallocz(sizeof(AVClass));",
"ret->av_class->item_name = filter_name;",
"ret->filter = filter;",
"ret->name = inst_name ? av_strdup(inst_name) : NULL;",
... | [
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
21
],
[
23
],
[
25
],
[
27
],
[
31
],
[
33
],
[
35
],
[
37
],
[
41
],
[
43
]
] |
15,137 | static int vnc_zlib_stop(VncState *vs)
{
z_streamp zstream = &vs->zlib.stream;
int previous_out;
// switch back to normal output/zlib buffers
vs->zlib.zlib = vs->output;
vs->output = vs->zlib.tmp;
// compress the zlib buffer
// initialize the stream
// XXX need one stream ... | true | qemu | 2caa9e9d2e0f356cc244bc41ce1d3e81663f6782 | static int vnc_zlib_stop(VncState *vs)
{
z_streamp zstream = &vs->zlib.stream;
int previous_out;
vs->zlib.zlib = vs->output;
vs->output = vs->zlib.tmp;
if (zstream->opaque != vs) {
int err;
VNC_DEBUG("VNC: initializing zlib stream\n");
... | {
"code": [
" previous_out = zstream->total_out;",
" previous_out = zstream->total_out;",
" return zstream->total_out - previous_out;"
],
"line_no": [
101,
101,
119
]
} | static int FUNC_0(VncState *VAR_0)
{
z_streamp zstream = &VAR_0->zlib.stream;
int VAR_1;
VAR_0->zlib.zlib = VAR_0->output;
VAR_0->output = VAR_0->zlib.tmp;
if (zstream->opaque != VAR_0) {
int VAR_2;
VNC_DEBUG("VNC: initializing zlib stream\n");... | [
"static int FUNC_0(VncState *VAR_0)\n{",
"z_streamp zstream = &VAR_0->zlib.stream;",
"int VAR_1;",
"VAR_0->zlib.zlib = VAR_0->output;",
"VAR_0->output = VAR_0->zlib.tmp;",
"if (zstream->opaque != VAR_0) {",
"int VAR_2;",
"VNC_DEBUG(\"VNC: initializing zlib stream\\n\");",
"VNC_DEBUG(\"VNC: opaque = ... | [
0,
0,
0,
0,
0,
0,
0,
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,
1,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
13
],
[
15
],
[
27
],
[
29
],
[
33
],
[
35
],
[
37
],
[
39
],
[
43,
45
],
[
49
],
[
51
],
[
53
],
[
55
],
[
59
],
[
61
],
[
63
],
... |
15,138 | void OPPROTO op_divw_AX_T0(void)
{
unsigned int num, den, q, r;
num = (EAX & 0xffff) | ((EDX & 0xffff) << 16);
den = (T0 & 0xffff);
if (den == 0) {
raise_exception(EXCP00_DIVZ);
}
q = (num / den) & 0xffff;
r = (num % den) & 0xffff;
EAX = (EAX & ~0xffff) | q;
EDX ... | true | qemu | 45bbbb466cf4a6280076ea5a51f67ef5bedee345 | void OPPROTO op_divw_AX_T0(void)
{
unsigned int num, den, q, r;
num = (EAX & 0xffff) | ((EDX & 0xffff) << 16);
den = (T0 & 0xffff);
if (den == 0) {
raise_exception(EXCP00_DIVZ);
}
q = (num / den) & 0xffff;
r = (num % den) & 0xffff;
EAX = (EAX & ~0xffff) | q;
EDX ... | {
"code": [
" q = (num / den) & 0xffff;",
" q = (num / den) & 0xffff;"
],
"line_no": [
19,
19
]
} | void VAR_0 op_divw_AX_T0(void)
{
unsigned int num, den, q, r;
num = (EAX & 0xffff) | ((EDX & 0xffff) << 16);
den = (T0 & 0xffff);
if (den == 0) {
raise_exception(EXCP00_DIVZ);
}
q = (num / den) & 0xffff;
r = (num % den) & 0xffff;
EAX = (EAX & ~0xffff) | q;
EDX = ... | [
"void VAR_0 op_divw_AX_T0(void)\n{",
"unsigned int num, den, q, r;",
"num = (EAX & 0xffff) | ((EDX & 0xffff) << 16);",
"den = (T0 & 0xffff);",
"if (den == 0) {",
"raise_exception(EXCP00_DIVZ);",
"}",
"q = (num / den) & 0xffff;",
"r = (num % den) & 0xffff;",
"EAX = (EAX & ~0xffff) | q;",
"EDX = (... | [
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
]
] |
15,139 | static void fic_draw_cursor(AVCodecContext *avctx, int cur_x, int cur_y)
{
FICContext *ctx = avctx->priv_data;
uint8_t *ptr = ctx->cursor_buf;
uint8_t *dstptr[3];
uint8_t planes[4][1024];
uint8_t chroma[3][256];
int i, j, p;
/* Convert to YUVA444. */
for (i = 0; i < 1024; i... | true | FFmpeg | 7596fc3d4b616318ac42a6cc011fe20f3ff7aaa9 | static void fic_draw_cursor(AVCodecContext *avctx, int cur_x, int cur_y)
{
FICContext *ctx = avctx->priv_data;
uint8_t *ptr = ctx->cursor_buf;
uint8_t *dstptr[3];
uint8_t planes[4][1024];
uint8_t chroma[3][256];
int i, j, p;
for (i = 0; i < 1024; i++) {
planes[0][... | {
"code": [
" planes[0][i] = av_clip_uint8((( 25 * ptr[0] + 129 * ptr[1] + 66 * ptr[2]) / 255) + 16);",
" planes[1][i] = av_clip_uint8(((-38 * ptr[0] + 112 * ptr[1] + -74 * ptr[2]) / 255) + 128);",
" planes[2][i] = av_clip_uint8(((-18 * ptr[0] + 112 * ptr[1] + -94 * ptr[2]) / 255) + ... | static void FUNC_0(AVCodecContext *VAR_0, int VAR_1, int VAR_2)
{
FICContext *ctx = VAR_0->priv_data;
uint8_t *ptr = ctx->cursor_buf;
uint8_t *dstptr[3];
uint8_t planes[4][1024];
uint8_t chroma[3][256];
int VAR_3, VAR_4, VAR_5;
for (VAR_3 = 0; VAR_3 < 1024; VAR_3++) {
... | [
"static void FUNC_0(AVCodecContext *VAR_0, int VAR_1, int VAR_2)\n{",
"FICContext *ctx = VAR_0->priv_data;",
"uint8_t *ptr = ctx->cursor_buf;",
"uint8_t *dstptr[3];",
"uint8_t planes[4][1024];",
"uint8_t chroma[3][256];",
"int VAR_3, VAR_4, VAR_5;",
"for (VAR_3 = 0; VAR_3 < 1024; VAR_3++) {",
"pl... | [
0,
0,
0,
0,
0,
0,
0,
0,
1,
1,
1,
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
],
[
33
],
[
35
],
[
41
],
[
43
],
[
45
],
[
47,
49,
51,
53
],
[... |
15,140 | static int decode_ref_pic_list_reordering(H264Context *h){
MpegEncContext * const s = &h->s;
int list, index;
print_short_term(h);
print_long_term(h);
if(h->slice_type==I_TYPE || h->slice_type==SI_TYPE) return 0; //FIXME move before func
for(list=0; list<2; list++){
memcpy(h->... | true | FFmpeg | 88e7a4d18c63799a21dff4a570ceb8008e310820 | static int decode_ref_pic_list_reordering(H264Context *h){
MpegEncContext * const s = &h->s;
int list, index;
print_short_term(h);
print_long_term(h);
if(h->slice_type==I_TYPE || h->slice_type==SI_TYPE) return 0;
for(list=0; list<2; list++){
memcpy(h->ref_list[list], h->defau... | {
"code": [
" int reordering_of_pic_nums_idc= get_ue_golomb(&s->gb);",
" int pic_id;",
" const int abs_diff_pic_num= get_ue_golomb(&s->gb) + 1;"
],
"line_no": [
31,
33,
61
]
} | static int FUNC_0(H264Context *VAR_0){
MpegEncContext * const s = &VAR_0->s;
int VAR_1, VAR_2;
print_short_term(VAR_0);
print_long_term(VAR_0);
if(VAR_0->slice_type==I_TYPE || VAR_0->slice_type==SI_TYPE) return 0;
for(VAR_1=0; VAR_1<2; VAR_1++){
memcpy(VAR_0->ref_list[VAR_1],... | [
"static int FUNC_0(H264Context *VAR_0){",
"MpegEncContext * const s = &VAR_0->s;",
"int VAR_1, VAR_2;",
"print_short_term(VAR_0);",
"print_long_term(VAR_0);",
"if(VAR_0->slice_type==I_TYPE || VAR_0->slice_type==SI_TYPE) return 0;",
"for(VAR_1=0; VAR_1<2; VAR_1++){",
"memcpy(VAR_0->ref_list[VAR_1], VAR... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
[
1
],
[
3
],
[
5
],
[
9
],
[
11
],
[
13
],
[
17
],
[
19
],
[
23
],
[
25
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
41,
43
],
[
47
],
[
49
],
[
51
],
[
53... |
15,141 | TCGOp *tcg_op_insert_before(TCGContext *s, TCGOp *old_op,
TCGOpcode opc, int nargs)
{
int oi = s->gen_next_op_idx;
int prev = old_op->prev;
int next = old_op - s->gen_op_buf;
TCGOp *new_op;
tcg_debug_assert(oi < OPC_BUF_SIZE);
s->gen_next_op_idx = oi + 1;
... | true | qemu | 15fa08f8451babc88d733bd411d4c94976f9d0f8 | TCGOp *tcg_op_insert_before(TCGContext *s, TCGOp *old_op,
TCGOpcode opc, int nargs)
{
int oi = s->gen_next_op_idx;
int prev = old_op->prev;
int next = old_op - s->gen_op_buf;
TCGOp *new_op;
tcg_debug_assert(oi < OPC_BUF_SIZE);
s->gen_next_op_idx = oi + 1;
... | {
"code": [
" tcg_debug_assert(oi < OPC_BUF_SIZE);",
"TCGOp *tcg_op_insert_before(TCGContext *s, TCGOp *old_op,",
" TCGOpcode opc, int nargs)",
" int oi = s->gen_next_op_idx;",
" int prev = old_op->prev;",
" int next = old_op - s->gen_op_buf;",
" T... | TCGOp *FUNC_0(TCGContext *s, TCGOp *old_op,
TCGOpcode opc, int nargs)
{
int VAR_0 = s->gen_next_op_idx;
int VAR_1 = old_op->VAR_1;
int VAR_2 = old_op - s->gen_op_buf;
TCGOp *new_op;
tcg_debug_assert(VAR_0 < OPC_BUF_SIZE);
s->gen_next_op_idx = VAR_0 + 1;
... | [
"TCGOp *FUNC_0(TCGContext *s, TCGOp *old_op,\nTCGOpcode opc, int nargs)\n{",
"int VAR_0 = s->gen_next_op_idx;",
"int VAR_1 = old_op->VAR_1;",
"int VAR_2 = old_op - s->gen_op_buf;",
"TCGOp *new_op;",
"tcg_debug_assert(VAR_0 < OPC_BUF_SIZE);",
"s->gen_next_op_idx = VAR_0 + 1;",
"new_op = &s->gen_op_buf[... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
17
],
[
19
],
[
23
],
[
25
],
[
27,
29,
31,
33
],
[
35
],
[
37
],
[
41
],
[
43
]
] |
15,142 | void FUNCC(ff_h264_idct8_dc_add)(uint8_t *_dst, DCTELEM *block, int stride){
int i, j;
int dc = (((dctcoef*)block)[0] + 32) >> 6;
INIT_CLIP
pixel *dst = (pixel*)_dst;
stride /= sizeof(pixel);
for( j = 0; j < 8; j++ )
{
for( i = 0; i < 8; i++ )
dst[i] = CLIP( dst[... | true | FFmpeg | c23acbaed40101c677dfcfbbfe0d2c230a8e8f44 | void FUNCC(ff_h264_idct8_dc_add)(uint8_t *_dst, DCTELEM *block, int stride){
int i, j;
int dc = (((dctcoef*)block)[0] + 32) >> 6;
INIT_CLIP
pixel *dst = (pixel*)_dst;
stride /= sizeof(pixel);
for( j = 0; j < 8; j++ )
{
for( i = 0; i < 8; i++ )
dst[i] = CLIP( dst[... | {
"code": [
" INIT_CLIP",
" INIT_CLIP",
" INIT_CLIP",
" dst[i] = CLIP( dst[i] + dc );",
" INIT_CLIP",
" dst[i] = CLIP( dst[i] + dc );"
],
"line_no": [
7,
7,
7,
19,
7,
19
]
} | void FUNC_0(ff_h264_idct8_dc_add)(uint8_t *_dst, DCTELEM *block, int stride){
int VAR_0, VAR_1;
int VAR_2 = (((dctcoef*)block)[0] + 32) >> 6;
INIT_CLIP
pixel *dst = (pixel*)_dst;
stride /= sizeof(pixel);
for( VAR_1 = 0; VAR_1 < 8; VAR_1++ )
{
for( VAR_0 = 0; VAR_0 < 8; VAR_0+... | [
"void FUNC_0(ff_h264_idct8_dc_add)(uint8_t *_dst, DCTELEM *block, int stride){",
"int VAR_0, VAR_1;",
"int VAR_2 = (((dctcoef*)block)[0] + 32) >> 6;",
"INIT_CLIP\npixel *dst = (pixel*)_dst;",
"stride /= sizeof(pixel);",
"for( VAR_1 = 0; VAR_1 < 8; VAR_1++ )",
"{",
"for( VAR_0 = 0; VAR_0 < 8; VAR_0++ )... | [
0,
0,
0,
1,
0,
0,
0,
0,
1,
0,
0,
0
] | [
[
1
],
[
3
],
[
5
],
[
7,
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
]
] |
15,143 | static int svq3_decode_frame(AVCodecContext *avctx, void *data,
int *got_frame, AVPacket *avpkt)
{
const uint8_t *buf = avpkt->data;
SVQ3Context *svq3 = avctx->priv_data;
H264Context *h = &svq3->h;
MpegEncContext *s = &h->s;
int buf_size = avpkt->size;... | true | FFmpeg | 9a2e79116d6235c53d8e9663a8d30d1950d7431a | static int svq3_decode_frame(AVCodecContext *avctx, void *data,
int *got_frame, AVPacket *avpkt)
{
const uint8_t *buf = avpkt->data;
SVQ3Context *svq3 = avctx->priv_data;
H264Context *h = &svq3->h;
MpegEncContext *s = &h->s;
int buf_size = avpkt->size;... | {
"code": [
" return -1;",
" int m, mb_type;",
" if ((unsigned)mb_type > 33 || svq3_decode_mb(svq3, mb_type)) {"
],
"line_no": [
229,
17,
223
]
} | static int FUNC_0(AVCodecContext *VAR_0, void *VAR_1,
int *VAR_2, AVPacket *VAR_3)
{
const uint8_t *VAR_4 = VAR_3->VAR_1;
SVQ3Context *svq3 = VAR_0->priv_data;
H264Context *h = &svq3->h;
MpegEncContext *s = &h->s;
int VAR_5 = VAR_3->size;
int VAR_... | [
"static int FUNC_0(AVCodecContext *VAR_0, void *VAR_1,\nint *VAR_2, AVPacket *VAR_3)\n{",
"const uint8_t *VAR_4 = VAR_3->VAR_1;",
"SVQ3Context *svq3 = VAR_0->priv_data;",
"H264Context *h = &svq3->h;",
"MpegEncContext *s = &h->s;",
"int VAR_5 = VAR_3->size;",
"int VAR_6, VAR_7;",
"if (VAR_5... | [
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,
0,
1... | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
41
],
[
45
],
[
49,
51
],
[
55
... |
15,144 | static void mpeg4_decode_sprite_trajectory(MpegEncContext * s, GetBitContext *gb)
{
int i;
int a= 2<<s->sprite_warping_accuracy;
int rho= 3-s->sprite_warping_accuracy;
int r=16/a;
const int vop_ref[4][2]= {{0,0}, {s->width,0}, {0, s->height}, {s->width, s->height}}; // only true for rectangle ... | true | FFmpeg | fc5c49ab3247533e0a5cb203cf7122143389eb5c | static void mpeg4_decode_sprite_trajectory(MpegEncContext * s, GetBitContext *gb)
{
int i;
int a= 2<<s->sprite_warping_accuracy;
int rho= 3-s->sprite_warping_accuracy;
int r=16/a;
const int vop_ref[4][2]= {{0,0}, {s->width,0}, {0, s->height}, {s->width, s->height}};
int d[4][2]={{0,0}, {... | {
"code": [
"static void mpeg4_decode_sprite_trajectory(MpegEncContext * s, GetBitContext *gb)"
],
"line_no": [
1
]
} | static void FUNC_0(MpegEncContext * VAR_0, GetBitContext *VAR_1)
{
int VAR_2;
int VAR_3= 2<<VAR_0->sprite_warping_accuracy;
int VAR_4= 3-VAR_0->sprite_warping_accuracy;
int VAR_5=16/VAR_3;
const int VAR_6[4][2]= {{0,0}, {VAR_0->width,0}, {0, VAR_0->height}, {VAR_0->width, VAR_0->height}};
... | [
"static void FUNC_0(MpegEncContext * VAR_0, GetBitContext *VAR_1)\n{",
"int VAR_2;",
"int VAR_3= 2<<VAR_0->sprite_warping_accuracy;",
"int VAR_4= 3-VAR_0->sprite_warping_accuracy;",
"int VAR_5=16/VAR_3;",
"const int VAR_6[4][2]= {{0,0}, {VAR_0->width,0}, {0, VAR_0->height}, {VAR_0->width, VAR_0->height}};... | [
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
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
33
],
[
35
],
[
37
],
[
41
],
[
43
],
[
45
... |
15,145 | static int parse(AVCodecParserContext *ctx,
AVCodecContext *avctx,
const uint8_t **out_data, int *out_size,
const uint8_t *data, int size)
{
VP9ParseContext *s = ctx->priv_data;
int full_size = size;
int marker;
if (size <= 0) {
*out_... | true | FFmpeg | 7b4367d93ea2a34baeab2c734630df5e0f11d4c1 | static int parse(AVCodecParserContext *ctx,
AVCodecContext *avctx,
const uint8_t **out_data, int *out_size,
const uint8_t *data, int size)
{
VP9ParseContext *s = ctx->priv_data;
int full_size = size;
int marker;
if (size <= 0) {
*out_... | {
"code": [
" if (sz > size) { \\",
" \"Superframe packet size too big: %u > %d\\n\", \\"
],
"line_no": [
79,
89
]
} | 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)
{
VP9ParseContext *s = VAR_0->priv_data;
int VAR_6 = VAR_5;
int VAR_7;
if (VAR_5 <= 0) {
*VAR_3 ... | [
"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{",
"VP9ParseContext *s = VAR_0->priv_data;",
"int VAR_6 = VAR_5;",
"int VAR_7;",
"if (VAR_5 <= 0) {",
"*VAR_3 = 0;",
"*VAR_2 = VAR_4;",
"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,
1,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5,
7,
9
],
[
11
],
[
13
],
[
15
],
[
19
],
[
21
],
[
23
],
[
27
],
[
29
],
[
33
],
[
35
],
[
37
],
[
39
],
[
43
],
[
45
],
[
49
],
[
51
],
[
53
],
[... |
15,146 | void axisdev88_init(MachineState *machine)
{
ram_addr_t ram_size = machine->ram_size;
const char *cpu_model = machine->cpu_model;
const char *kernel_filename = machine->kernel_filename;
const char *kernel_cmdline = machine->kernel_cmdline;
CRISCPU *cpu;
CPUCRISState *env;
DeviceState... | true | qemu | f8ed85ac992c48814d916d5df4d44f9a971c5de4 | void axisdev88_init(MachineState *machine)
{
ram_addr_t ram_size = machine->ram_size;
const char *cpu_model = machine->cpu_model;
const char *kernel_filename = machine->kernel_filename;
const char *kernel_cmdline = machine->kernel_cmdline;
CRISCPU *cpu;
CPUCRISState *env;
DeviceState... | {
"code": [
" &error_abort);",
" &error_abort);",
" &error_abort);",
" &error_abort);",
" &error_abort);",
" &error_abort);",
" ... | void FUNC_0(MachineState *VAR_0)
{
ram_addr_t ram_size = VAR_0->ram_size;
const char *VAR_1 = VAR_0->VAR_1;
const char *VAR_2 = VAR_0->VAR_2;
const char *VAR_3 = VAR_0->VAR_3;
CRISCPU *cpu;
CPUCRISState *env;
DeviceState *dev;
SysBusDevice *s;
DriveInfo *nand;
qemu_irq... | [
"void FUNC_0(MachineState *VAR_0)\n{",
"ram_addr_t ram_size = VAR_0->ram_size;",
"const char *VAR_1 = VAR_0->VAR_1;",
"const char *VAR_2 = VAR_0->VAR_2;",
"const char *VAR_3 = VAR_0->VAR_3;",
"CRISCPU *cpu;",
"CPUCRISState *env;",
"DeviceState *dev;",
"SysBusDevice *s;",
"DriveInfo *nand;",
"qem... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
41
],
[
43
],
[
45
... |
15,148 | static int mjpeg_decode_app(MJpegDecodeContext *s)
{
int len, id, i;
len = get_bits(&s->gb, 16);
if (len < 6)
return AVERROR_INVALIDDATA;
if (8 * len > get_bits_left(&s->gb))
return AVERROR_INVALIDDATA;
id = get_bits_long(&s->gb, 32);
len -= 6;
if (s->avctx-... | true | FFmpeg | 4acea512f36b96256535b45b1a7e723c61c89c31 | static int mjpeg_decode_app(MJpegDecodeContext *s)
{
int len, id, i;
len = get_bits(&s->gb, 16);
if (len < 6)
return AVERROR_INVALIDDATA;
if (8 * len > get_bits_left(&s->gb))
return AVERROR_INVALIDDATA;
id = get_bits_long(&s->gb, 32);
len -= 6;
if (s->avctx-... | {
"code": [],
"line_no": []
} | static int FUNC_0(MJpegDecodeContext *VAR_0)
{
int VAR_1, VAR_2, VAR_3;
VAR_1 = get_bits(&VAR_0->gb, 16);
if (VAR_1 < 6)
return AVERROR_INVALIDDATA;
if (8 * VAR_1 > get_bits_left(&VAR_0->gb))
return AVERROR_INVALIDDATA;
VAR_2 = get_bits_long(&VAR_0->gb, 32);
VAR_1 ... | [
"static int FUNC_0(MJpegDecodeContext *VAR_0)\n{",
"int VAR_1, VAR_2, VAR_3;",
"VAR_1 = get_bits(&VAR_0->gb, 16);",
"if (VAR_1 < 6)\nreturn AVERROR_INVALIDDATA;",
"if (8 * VAR_1 > get_bits_left(&VAR_0->gb))\nreturn AVERROR_INVALIDDATA;",
"VAR_2 = get_bits_long(&VAR_0->gb, 32);",
"VAR_1 -= 6;",
"if (... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
[
1,
3
],
[
5
],
[
9
],
[
11,
13
],
[
15,
17
],
[
21
],
[
23
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
45
],
[
61
],
[
63
],
[
65
],
[
67,
69
],
[
71
],
... |
15,149 | static int do_decode(AVCodecContext *avctx, AVPacket *pkt)
{
int got_frame;
int ret;
av_assert0(!avctx->internal->buffer_frame->buf[0]);
if (!pkt)
pkt = avctx->internal->buffer_pkt;
// This is the lesser evil. The field is for compatibility with legacy users
// of the legac... | true | FFmpeg | b4b8ca24f62473528949fe047085eb084364124b | static int do_decode(AVCodecContext *avctx, AVPacket *pkt)
{
int got_frame;
int ret;
av_assert0(!avctx->internal->buffer_frame->buf[0]);
if (!pkt)
pkt = avctx->internal->buffer_pkt;
avctx->refcounted_frames = 1;
if (avctx->internal->draining_... | {
"code": [
" int got_frame;"
],
"line_no": [
5
]
} | static int FUNC_0(AVCodecContext *VAR_0, AVPacket *VAR_1)
{
int VAR_2;
int VAR_3;
av_assert0(!VAR_0->internal->buffer_frame->buf[0]);
if (!VAR_1)
VAR_1 = VAR_0->internal->buffer_pkt;
VAR_0->refcounted_frames = 1;
if (VAR_0->internal->draining... | [
"static int FUNC_0(AVCodecContext *VAR_0, AVPacket *VAR_1)\n{",
"int VAR_2;",
"int VAR_3;",
"av_assert0(!VAR_0->internal->buffer_frame->buf[0]);",
"if (!VAR_1)\nVAR_1 = VAR_0->internal->buffer_pkt;",
"VAR_0->refcounted_frames = 1;",
"if (VAR_0->internal->draining_done)\nreturn AVERROR_EOF;",
"if (VAR_... | [
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
] | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
15,
17
],
[
27
],
[
35,
37
],
[
41
],
[
43,
45
],
[
47,
49
],
[
51
],
[
53,
55
],
[
57
],
[
59
],
[
61
],
[
65,
67
],
[
71... |
15,150 | void ff_h264_free_tables(H264Context *h, int free_rbsp)
{
int i;
av_freep(&h->intra4x4_pred_mode);
av_freep(&h->chroma_pred_mode_table);
av_freep(&h->cbp_table);
av_freep(&h->mvd_table[0]);
av_freep(&h->mvd_table[1]);
av_freep(&h->direct_table);
av_freep(&h->non_zero_count);
... | true | FFmpeg | a6cd154463bea7eb56d28192db4c8c6d83f67fd7 | void ff_h264_free_tables(H264Context *h, int free_rbsp)
{
int i;
av_freep(&h->intra4x4_pred_mode);
av_freep(&h->chroma_pred_mode_table);
av_freep(&h->cbp_table);
av_freep(&h->mvd_table[0]);
av_freep(&h->mvd_table[1]);
av_freep(&h->direct_table);
av_freep(&h->non_zero_count);
... | {
"code": [
" if (free_rbsp && h->DPB) {",
" for (i = 0; i < H264_MAX_PICTURE_COUNT; i++)",
" ff_h264_unref_picture(h, &h->DPB[i]);",
" av_freep(&h->DPB);",
" h->cur_pic_ptr = NULL;",
" for (i = 0; i < H264_MAX_PICTURE_COUNT; i++)"
],
"line_no": [
... | void FUNC_0(H264Context *VAR_0, int VAR_1)
{
int VAR_2;
av_freep(&VAR_0->intra4x4_pred_mode);
av_freep(&VAR_0->chroma_pred_mode_table);
av_freep(&VAR_0->cbp_table);
av_freep(&VAR_0->mvd_table[0]);
av_freep(&VAR_0->mvd_table[1]);
av_freep(&VAR_0->direct_table);
av_freep(&VAR_0-... | [
"void FUNC_0(H264Context *VAR_0, int VAR_1)\n{",
"int VAR_2;",
"av_freep(&VAR_0->intra4x4_pred_mode);",
"av_freep(&VAR_0->chroma_pred_mode_table);",
"av_freep(&VAR_0->cbp_table);",
"av_freep(&VAR_0->mvd_table[0]);",
"av_freep(&VAR_0->mvd_table[1]);",
"av_freep(&VAR_0->direct_table);",
"av_freep(&VAR... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
1,
1,
1,
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
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
31
],
[
33
],
[
37
],
[
39
],
[
41
],
[
43
],
[
47
],
[
49... |
15,151 | static bool s390_gen_initial_iplb(S390IPLState *ipl)
{
DeviceState *dev_st;
dev_st = get_boot_device(0);
if (dev_st) {
VirtioCcwDevice *virtio_ccw_dev = (VirtioCcwDevice *)
object_dynamic_cast(OBJECT(qdev_get_parent_bus(dev_st)->parent),
TYPE_VIRTIO_CCW_DEVICE);
S... | true | qemu | f38b5b7fc4e27724afc72b91efa2bc82f84bb25e | static bool s390_gen_initial_iplb(S390IPLState *ipl)
{
DeviceState *dev_st;
dev_st = get_boot_device(0);
if (dev_st) {
VirtioCcwDevice *virtio_ccw_dev = (VirtioCcwDevice *)
object_dynamic_cast(OBJECT(qdev_get_parent_bus(dev_st)->parent),
TYPE_VIRTIO_CCW_DEVICE);
S... | {
"code": [],
"line_no": []
} | static bool FUNC_0(S390IPLState *ipl)
{
DeviceState *dev_st;
dev_st = get_boot_device(0);
if (dev_st) {
VirtioCcwDevice *virtio_ccw_dev = (VirtioCcwDevice *)
object_dynamic_cast(OBJECT(qdev_get_parent_bus(dev_st)->parent),
TYPE_VIRTIO_CCW_DEVICE);
SCSIDevice *sd =... | [
"static bool FUNC_0(S390IPLState *ipl)\n{",
"DeviceState *dev_st;",
"dev_st = get_boot_device(0);",
"if (dev_st) {",
"VirtioCcwDevice *virtio_ccw_dev = (VirtioCcwDevice *)\nobject_dynamic_cast(OBJECT(qdev_get_parent_bus(dev_st)->parent),\nTYPE_VIRTIO_CCW_DEVICE);",
"SCSIDevice *sd = (SCSIDevice *) object_... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
2
],
[
3
],
[
4
],
[
5
],
[
6,
7,
8
],
[
9,
10
],
[
11
],
[
12
],
[
13
],
[
14,
15
],
[
16
],
[
17
],
[
18
],
[
19
],
[
20
],
[
21
],
[
22
],
[
23
],... |
15,152 | static 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 ga... | true | FFmpeg | 067485b673f6ac4b1207d6fc975d1fd968edc68e | static 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... | {
"code": [
" s->pre_mantissa[ch][bin][blk] = ff_eac3_mantissa_vq[hebap][v][blk] << 8;",
" mant <<= (23 - (mbits - 1));",
" b = ff_eac3_gaq_remap_2_4_b[hebap-8][log_gain-1] << 8;"
],
"line_no": [
105,
143,
153
]
} | static 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 == EA... | [
"static 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_... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
1,
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
],
[... |
15,153 | int bdrv_pdiscard(BlockDriverState *bs, int64_t offset, int count)
{
Coroutine *co;
DiscardCo rwco = {
.bs = bs,
.offset = offset,
.count = count,
.ret = NOT_DONE,
};
if (qemu_in_coroutine()) {
/* Fast-path if already in coroutine context */
b... | true | qemu | e92f0e1910f0655a0edd8d87c5a7262d36517a89 | int bdrv_pdiscard(BlockDriverState *bs, int64_t offset, int count)
{
Coroutine *co;
DiscardCo rwco = {
.bs = bs,
.offset = offset,
.count = count,
.ret = NOT_DONE,
};
if (qemu_in_coroutine()) {
bdrv_pdiscard_co_entry(&rwco);
} else {
... | {
"code": [
" qemu_coroutine_enter(co);",
" qemu_coroutine_enter(co);",
" qemu_coroutine_enter(co);",
" qemu_coroutine_enter(co);",
" qemu_coroutine_enter(co);",
" qemu_coroutine_enter(co);"
],
"line_no": [
31,
31,
31,
31,
31,
... | int FUNC_0(BlockDriverState *VAR_0, int64_t VAR_1, int VAR_2)
{
Coroutine *co;
DiscardCo rwco = {
.VAR_0 = VAR_0,
.VAR_1 = VAR_1,
.VAR_2 = VAR_2,
.ret = NOT_DONE,
};
if (qemu_in_coroutine()) {
bdrv_pdiscard_co_entry(&rwco);
} else {
... | [
"int FUNC_0(BlockDriverState *VAR_0, int64_t VAR_1, int VAR_2)\n{",
"Coroutine *co;",
"DiscardCo rwco = {",
".VAR_0 = VAR_0,\n.VAR_1 = VAR_1,\n.VAR_2 = VAR_2,\n.ret = NOT_DONE,\n};",
"if (qemu_in_coroutine()) {",
"bdrv_pdiscard_co_entry(&rwco);",
"} else {",
"co = qemu_coroutine_create(bdrv_pdiscard_c... | [
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9,
11,
13,
15,
17
],
[
21
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
39
],
[
41
]
] |
15,154 | static void alpha_cpu_initfn(Object *obj)
{
CPUState *cs = CPU(obj);
AlphaCPU *cpu = ALPHA_CPU(obj);
CPUAlphaState *env = &cpu->env;
cs->env_ptr = env;
cpu_exec_init(cs, &error_abort);
tlb_flush(cs, 1);
alpha_translate_init();
#if defined(CONFIG_USER_ONLY)
env->ps = PS_US... | true | qemu | ce5b1bbf624b977a55ff7f85bb3871682d03baff | static void alpha_cpu_initfn(Object *obj)
{
CPUState *cs = CPU(obj);
AlphaCPU *cpu = ALPHA_CPU(obj);
CPUAlphaState *env = &cpu->env;
cs->env_ptr = env;
cpu_exec_init(cs, &error_abort);
tlb_flush(cs, 1);
alpha_translate_init();
#if defined(CONFIG_USER_ONLY)
env->ps = PS_US... | {
"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);
AlphaCPU *cpu = ALPHA_CPU(VAR_0);
CPUAlphaState *env = &cpu->env;
cs->env_ptr = env;
cpu_exec_init(cs, &error_abort);
tlb_flush(cs, 1);
alpha_translate_init();
#if defined(CONFIG_USER_ONLY)
env->ps = PS_USER_M... | [
"static void FUNC_0(Object *VAR_0)\n{",
"CPUState *cs = CPU(VAR_0);",
"AlphaCPU *cpu = ALPHA_CPU(VAR_0);",
"CPUAlphaState *env = &cpu->env;",
"cs->env_ptr = env;",
"cpu_exec_init(cs, &error_abort);",
"tlb_flush(cs, 1);",
"alpha_translate_init();",
"#if defined(CONFIG_USER_ONLY)\nenv->ps = PS_USER_MO... | [
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
17
],
[
21
],
[
25,
27
],
[
29,
31,
33
],
[
35,
37
],
[
39
],
[
41
]
] |
15,155 | static void render_line(int x0, int y0, int x1, int y1, float *buf)
{
int dy = y1 - y0;
int adx = x1 - x0;
int ady = FFABS(dy);
int sy = dy < 0 ? -1 : 1;
buf[x0] = ff_vorbis_floor1_inverse_db_table[y0];
if (ady*2 <= adx) { // optimized common case
render_line_unrolled(x0, y0, x... | true | FFmpeg | 7149fce2cac0474a5fbc5b47add1158cd8bb283e | static void render_line(int x0, int y0, int x1, int y1, float *buf)
{
int dy = y1 - y0;
int adx = x1 - x0;
int ady = FFABS(dy);
int sy = dy < 0 ? -1 : 1;
buf[x0] = ff_vorbis_floor1_inverse_db_table[y0];
if (ady*2 <= adx) {
render_line_unrolled(x0, y0, x1, sy, ady, adx, buf);
... | {
"code": [
" int y = y0;"
],
"line_no": [
25
]
} | static void FUNC_0(int VAR_0, int VAR_1, int VAR_2, int VAR_3, float *VAR_4)
{
int VAR_5 = VAR_3 - VAR_1;
int VAR_6 = VAR_2 - VAR_0;
int VAR_7 = FFABS(VAR_5);
int VAR_8 = VAR_5 < 0 ? -1 : 1;
VAR_4[VAR_0] = ff_vorbis_floor1_inverse_db_table[VAR_1];
if (VAR_7*2 <= VAR_6) {
rende... | [
"static void FUNC_0(int VAR_0, int VAR_1, int VAR_2, int VAR_3, float *VAR_4)\n{",
"int VAR_5 = VAR_3 - VAR_1;",
"int VAR_6 = VAR_2 - VAR_0;",
"int VAR_7 = FFABS(VAR_5);",
"int VAR_8 = VAR_5 < 0 ? -1 : 1;",
"VAR_4[VAR_0] = ff_vorbis_floor1_inverse_db_table[VAR_1];",
"if (VAR_7*2 <= VAR_6) {",
"rende... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
... |
15,156 | void ram_control_after_iterate(QEMUFile *f, uint64_t flags)
{
int ret = 0;
if (f->ops->after_ram_iterate) {
ret = f->ops->after_ram_iterate(f, f->opaque, flags);
if (ret < 0) {
qemu_file_set_error(f, ret);
}
}
}
| true | qemu | 60fe637bf0e4d7989e21e50f52526444765c63b4 | void ram_control_after_iterate(QEMUFile *f, uint64_t flags)
{
int ret = 0;
if (f->ops->after_ram_iterate) {
ret = f->ops->after_ram_iterate(f, f->opaque, flags);
if (ret < 0) {
qemu_file_set_error(f, ret);
}
}
}
| {
"code": [],
"line_no": []
} | void FUNC_0(QEMUFile *VAR_0, uint64_t VAR_1)
{
int VAR_2 = 0;
if (VAR_0->ops->after_ram_iterate) {
VAR_2 = VAR_0->ops->after_ram_iterate(VAR_0, VAR_0->opaque, VAR_1);
if (VAR_2 < 0) {
qemu_file_set_error(VAR_0, VAR_2);
}
}
}
| [
"void FUNC_0(QEMUFile *VAR_0, uint64_t VAR_1)\n{",
"int VAR_2 = 0;",
"if (VAR_0->ops->after_ram_iterate) {",
"VAR_2 = VAR_0->ops->after_ram_iterate(VAR_0, VAR_0->opaque, VAR_1);",
"if (VAR_2 < 0) {",
"qemu_file_set_error(VAR_0, VAR_2);",
"}",
"}",
"}"
] | [
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
]
] |
15,157 | void ff_rtsp_close_streams(AVFormatContext *s)
{
RTSPState *rt = s->priv_data;
int i;
RTSPStream *rtsp_st;
ff_rtsp_undo_setup(s);
for (i = 0; i < rt->nb_rtsp_streams; i++) {
rtsp_st = rt->rtsp_streams[i];
if (rtsp_st) {
if (rtsp_st->dynamic_handler && rtsp_st->... | true | FFmpeg | ea7f080749d68a431226ce196014da38761a0d82 | void ff_rtsp_close_streams(AVFormatContext *s)
{
RTSPState *rt = s->priv_data;
int i;
RTSPStream *rtsp_st;
ff_rtsp_undo_setup(s);
for (i = 0; i < rt->nb_rtsp_streams; i++) {
rtsp_st = rt->rtsp_streams[i];
if (rtsp_st) {
if (rtsp_st->dynamic_handler && rtsp_st->... | {
"code": [],
"line_no": []
} | void FUNC_0(AVFormatContext *VAR_0)
{
RTSPState *rt = VAR_0->priv_data;
int VAR_1;
RTSPStream *rtsp_st;
ff_rtsp_undo_setup(VAR_0);
for (VAR_1 = 0; VAR_1 < rt->nb_rtsp_streams; VAR_1++) {
rtsp_st = rt->rtsp_streams[VAR_1];
if (rtsp_st) {
if (rtsp_st->dynamic_han... | [
"void FUNC_0(AVFormatContext *VAR_0)\n{",
"RTSPState *rt = VAR_0->priv_data;",
"int VAR_1;",
"RTSPStream *rtsp_st;",
"ff_rtsp_undo_setup(VAR_0);",
"for (VAR_1 = 0; VAR_1 < rt->nb_rtsp_streams; VAR_1++) {",
"rtsp_st = rt->rtsp_streams[VAR_1];",
"if (rtsp_st) {",
"if (rtsp_st->dynamic_handler && rtsp_... | [
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
],
[
28
],
[
30
],
[
32
],
[
34
],
[
36
],
[
38
],
[
40
],
[
42
],
[
44
],
[
46
... |
15,158 | static void aarch64_tr_insn_start(DisasContextBase *dcbase, CPUState *cpu)
{
DisasContext *dc = container_of(dcbase, DisasContext, base);
dc->insn_start_idx = tcg_op_buf_count();
tcg_gen_insn_start(dc->pc, 0, 0);
}
| true | qemu | 15fa08f8451babc88d733bd411d4c94976f9d0f8 | static void aarch64_tr_insn_start(DisasContextBase *dcbase, CPUState *cpu)
{
DisasContext *dc = container_of(dcbase, DisasContext, base);
dc->insn_start_idx = tcg_op_buf_count();
tcg_gen_insn_start(dc->pc, 0, 0);
}
| {
"code": [
" dc->insn_start_idx = tcg_op_buf_count();",
" dc->insn_start_idx = tcg_op_buf_count();"
],
"line_no": [
9,
9
]
} | static void FUNC_0(DisasContextBase *VAR_0, CPUState *VAR_1)
{
DisasContext *dc = container_of(VAR_0, DisasContext, base);
dc->insn_start_idx = tcg_op_buf_count();
tcg_gen_insn_start(dc->pc, 0, 0);
}
| [
"static void FUNC_0(DisasContextBase *VAR_0, CPUState *VAR_1)\n{",
"DisasContext *dc = container_of(VAR_0, DisasContext, base);",
"dc->insn_start_idx = tcg_op_buf_count();",
"tcg_gen_insn_start(dc->pc, 0, 0);",
"}"
] | [
0,
0,
1,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
],
[
13
]
] |
15,160 | int ff_xvid_rate_control_init(MpegEncContext *s){
char *tmp_name;
int fd, i;
xvid_plg_create_t xvid_plg_create = { 0 };
xvid_plugin_2pass2_t xvid_2pass2 = { 0 };
fd=av_tempfile("xvidrc.", &tmp_name, 0, s->avctx);
if (fd == -1) {
av_log(NULL, AV_LOG_ERROR, "Can't create temporar... | true | FFmpeg | 229ccce6cca7748f53cb4b6a8d035ddce5ac6b72 | int ff_xvid_rate_control_init(MpegEncContext *s){
char *tmp_name;
int fd, i;
xvid_plg_create_t xvid_plg_create = { 0 };
xvid_plugin_2pass2_t xvid_2pass2 = { 0 };
fd=av_tempfile("xvidrc.", &tmp_name, 0, s->avctx);
if (fd == -1) {
av_log(NULL, AV_LOG_ERROR, "Can't create temporar... | {
"code": [],
"line_no": []
} | int FUNC_0(MpegEncContext *VAR_0){
char *VAR_1;
int VAR_2, VAR_3;
xvid_plg_create_t xvid_plg_create = { 0 };
xvid_plugin_2pass2_t xvid_2pass2 = { 0 };
VAR_2=av_tempfile("xvidrc.", &VAR_1, 0, VAR_0->avctx);
if (VAR_2 == -1) {
av_log(NULL, AV_LOG_ERROR, "Can't create temporary pa... | [
"int FUNC_0(MpegEncContext *VAR_0){",
"char *VAR_1;",
"int VAR_2, VAR_3;",
"xvid_plg_create_t xvid_plg_create = { 0 };",
"xvid_plugin_2pass2_t xvid_2pass2 = { 0 };",
"VAR_2=av_tempfile(\"xvidrc.\", &VAR_1, 0, VAR_0->avctx);",
"if (VAR_2 == -1) {",
"av_log(NULL, AV_LOG_ERROR, \"Can't create temporary ... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
25
],
[
27
],
[
29
],
[
31
],
[
35
],
[
39,
41,
43
],
[
47
],
[
49
],
[
53
],
[... |
15,161 | void *fw_cfg_modify_file(FWCfgState *s, const char *filename,
void *data, size_t len)
{
int i, index;
void *ptr = NULL;
assert(s->files);
index = be32_to_cpu(s->files->count);
assert(index < fw_cfg_file_slots(s));
for (i = 0; i < index; i++) {
if (s... | true | qemu | d6b6abc51dda79a97f2c7bd6652c1940c068f1ec | void *fw_cfg_modify_file(FWCfgState *s, const char *filename,
void *data, size_t len)
{
int i, index;
void *ptr = NULL;
assert(s->files);
index = be32_to_cpu(s->files->count);
assert(index < fw_cfg_file_slots(s));
for (i = 0; i < index; i++) {
if (s... | {
"code": [
" assert(index < fw_cfg_file_slots(s));"
],
"line_no": [
19
]
} | void *FUNC_0(FWCfgState *VAR_0, const char *VAR_1,
void *VAR_2, size_t VAR_3)
{
int VAR_4, VAR_5;
void *VAR_6 = NULL;
assert(VAR_0->files);
VAR_5 = be32_to_cpu(VAR_0->files->count);
assert(VAR_5 < fw_cfg_file_slots(VAR_0));
for (VAR_4 = 0; VAR_4 < VAR_5; VAR... | [
"void *FUNC_0(FWCfgState *VAR_0, const char *VAR_1,\nvoid *VAR_2, size_t VAR_3)\n{",
"int VAR_4, VAR_5;",
"void *VAR_6 = NULL;",
"assert(VAR_0->files);",
"VAR_5 = be32_to_cpu(VAR_0->files->count);",
"assert(VAR_5 < fw_cfg_file_slots(VAR_0));",
"for (VAR_4 = 0; VAR_4 < VAR_5; VAR_4++) {",
"if (strcmp(V... | [
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
13
],
[
17
],
[
19
],
[
23
],
[
25
],
[
27,
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
41
],
[
43
],
[
45
]
] |
15,162 | int do_drive_del(Monitor *mon, const QDict *qdict, QObject **ret_data)
{
const char *id = qdict_get_str(qdict, "id");
BlockDriverState *bs;
bs = bdrv_find(id);
if (!bs) {
qerror_report(QERR_DEVICE_NOT_FOUND, id);
return -1;
}
if (bdrv_in_use(bs)) {
qerror_repo... | false | qemu | 922453bca6a927bb527068ae8679d587cfa45dbc | int do_drive_del(Monitor *mon, const QDict *qdict, QObject **ret_data)
{
const char *id = qdict_get_str(qdict, "id");
BlockDriverState *bs;
bs = bdrv_find(id);
if (!bs) {
qerror_report(QERR_DEVICE_NOT_FOUND, id);
return -1;
}
if (bdrv_in_use(bs)) {
qerror_repo... | {
"code": [],
"line_no": []
} | int FUNC_0(Monitor *VAR_0, const QDict *VAR_1, QObject **VAR_2)
{
const char *VAR_3 = qdict_get_str(VAR_1, "VAR_3");
BlockDriverState *bs;
bs = bdrv_find(VAR_3);
if (!bs) {
qerror_report(QERR_DEVICE_NOT_FOUND, VAR_3);
return -1;
}
if (bdrv_in_use(bs)) {
qerror... | [
"int FUNC_0(Monitor *VAR_0, const QDict *VAR_1, QObject **VAR_2)\n{",
"const char *VAR_3 = qdict_get_str(VAR_1, \"VAR_3\");",
"BlockDriverState *bs;",
"bs = bdrv_find(VAR_3);",
"if (!bs) {",
"qerror_report(QERR_DEVICE_NOT_FOUND, VAR_3);",
"return -1;",
"}",
"if (bdrv_in_use(bs)) {",
"qerror_report... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
33
],
[
35
],
[
37
],
[
51
],
[
53
],
[
55
],
[
57
],
[
59... |
15,164 | static void init_proc_970FX (CPUPPCState *env)
{
gen_spr_ne_601(env);
gen_spr_7xx(env);
/* Time base */
gen_tbl(env);
/* Hardware implementation registers */
/* XXX : not implemented */
spr_register(env, SPR_HID0, "HID0",
SPR_NOACCESS, SPR_NOACCESS,
... | false | qemu | bbc01ca7f265f2c5be8aee7c9ce1d10aa26063f5 | static void init_proc_970FX (CPUPPCState *env)
{
gen_spr_ne_601(env);
gen_spr_7xx(env);
gen_tbl(env);
spr_register(env, SPR_HID0, "HID0",
SPR_NOACCESS, SPR_NOACCESS,
&spr_read_generic, &spr_write_clear,
0x60000000);
... | {
"code": [],
"line_no": []
} | static void FUNC_0 (CPUPPCState *VAR_0)
{
gen_spr_ne_601(VAR_0);
gen_spr_7xx(VAR_0);
gen_tbl(VAR_0);
spr_register(VAR_0, SPR_HID0, "HID0",
SPR_NOACCESS, SPR_NOACCESS,
&spr_read_generic, &spr_write_clear,
0x60000000);
... | [
"static void FUNC_0 (CPUPPCState *VAR_0)\n{",
"gen_spr_ne_601(VAR_0);",
"gen_spr_7xx(VAR_0);",
"gen_tbl(VAR_0);",
"spr_register(VAR_0, SPR_HID0, \"HID0\",\nSPR_NOACCESS, SPR_NOACCESS,\n&spr_read_generic, &spr_write_clear,\n0x60000000);",
"spr_register(VAR_0, SPR_HID1, \"HID1\",\nSPR_NOACCESS, SPR_NOACCESS... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
17,
19,
21,
23
],
[
27,
29,
31,
33
],
[
37,
39,
41,
43
],
[
49
],
[
51,
53,
55,
57
],
[
59,
61,
63,
65
],
[
67,
69,
71,
73... |
15,165 | static QPCIBus *pci_test_start(int socket)
{
char *cmdline;
cmdline = g_strdup_printf("-netdev socket,fd=%d,id=hs0 -device "
"virtio-net-pci,netdev=hs0", socket);
qtest_start(cmdline);
g_free(cmdline);
return qpci_init_pc(NULL);
}
| false | qemu | a980f7f2c2f4d7e9a1eba4f804cd66dbd458b6d4 | static QPCIBus *pci_test_start(int socket)
{
char *cmdline;
cmdline = g_strdup_printf("-netdev socket,fd=%d,id=hs0 -device "
"virtio-net-pci,netdev=hs0", socket);
qtest_start(cmdline);
g_free(cmdline);
return qpci_init_pc(NULL);
}
| {
"code": [],
"line_no": []
} | static QPCIBus *FUNC_0(int socket)
{
char *VAR_0;
VAR_0 = g_strdup_printf("-netdev socket,fd=%d,id=hs0 -device "
"virtio-net-pci,netdev=hs0", socket);
qtest_start(VAR_0);
g_free(VAR_0);
return qpci_init_pc(NULL);
}
| [
"static QPCIBus *FUNC_0(int socket)\n{",
"char *VAR_0;",
"VAR_0 = g_strdup_printf(\"-netdev socket,fd=%d,id=hs0 -device \"\n\"virtio-net-pci,netdev=hs0\", socket);",
"qtest_start(VAR_0);",
"g_free(VAR_0);",
"return qpci_init_pc(NULL);",
"}"
] | [
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9,
11
],
[
13
],
[
15
],
[
19
],
[
21
]
] |
15,166 | static void ppc_prep_init(QEMUMachineInitArgs *args)
{
ram_addr_t ram_size = args->ram_size;
const char *cpu_model = args->cpu_model;
const char *kernel_filename = args->kernel_filename;
const char *kernel_cmdline = args->kernel_cmdline;
const char *initrd_filename = args->initrd_filename;
... | false | qemu | c16547326988cc321c9bff43ed91cbe753e52892 | static void ppc_prep_init(QEMUMachineInitArgs *args)
{
ram_addr_t ram_size = args->ram_size;
const char *cpu_model = args->cpu_model;
const char *kernel_filename = args->kernel_filename;
const char *kernel_cmdline = args->kernel_cmdline;
const char *initrd_filename = args->initrd_filename;
... | {
"code": [],
"line_no": []
} | static void FUNC_0(QEMUMachineInitArgs *VAR_0)
{
ram_addr_t ram_size = VAR_0->ram_size;
const char *VAR_1 = VAR_0->VAR_1;
const char *VAR_2 = VAR_0->VAR_2;
const char *VAR_3 = VAR_0->VAR_3;
const char *VAR_4 = VAR_0->VAR_4;
const char *VAR_5 = VAR_0->VAR_5;
MemoryRegion *sysmem = get... | [
"static void FUNC_0(QEMUMachineInitArgs *VAR_0)\n{",
"ram_addr_t ram_size = VAR_0->ram_size;",
"const char *VAR_1 = VAR_0->VAR_1;",
"const char *VAR_2 = VAR_0->VAR_2;",
"const char *VAR_3 = VAR_0->VAR_3;",
"const char *VAR_4 = VAR_0->VAR_4;",
"const char *VAR_5 = VAR_0->VAR_5;",
"MemoryRegion *sysmem ... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
... |
15,167 | static void smc91c111_cleanup(NetClientState *nc)
{
smc91c111_state *s = qemu_get_nic_opaque(nc);
s->nic = NULL;
}
| false | qemu | 57407ea44cc0a3d630b9b89a2be011f1955ce5c1 | static void smc91c111_cleanup(NetClientState *nc)
{
smc91c111_state *s = qemu_get_nic_opaque(nc);
s->nic = NULL;
}
| {
"code": [],
"line_no": []
} | static void FUNC_0(NetClientState *VAR_0)
{
smc91c111_state *s = qemu_get_nic_opaque(VAR_0);
s->nic = NULL;
}
| [
"static void FUNC_0(NetClientState *VAR_0)\n{",
"smc91c111_state *s = qemu_get_nic_opaque(VAR_0);",
"s->nic = NULL;",
"}"
] | [
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
]
] |
15,168 | e1000e_setup_tx_offloads(E1000ECore *core, struct e1000e_tx *tx)
{
if (tx->props.tse && tx->props.cptse) {
net_tx_pkt_build_vheader(tx->tx_pkt, true, true, tx->props.mss);
net_tx_pkt_update_ip_checksums(tx->tx_pkt);
e1000x_inc_reg_if_not_full(core->mac, TSCTC);
return;
}
... | false | qemu | 7d08c73e7bdc39b10e5f2f5acdce700f17ffe962 | e1000e_setup_tx_offloads(E1000ECore *core, struct e1000e_tx *tx)
{
if (tx->props.tse && tx->props.cptse) {
net_tx_pkt_build_vheader(tx->tx_pkt, true, true, tx->props.mss);
net_tx_pkt_update_ip_checksums(tx->tx_pkt);
e1000x_inc_reg_if_not_full(core->mac, TSCTC);
return;
}
... | {
"code": [],
"line_no": []
} | FUNC_0(E1000ECore *VAR_0, struct e1000e_tx *VAR_1)
{
if (VAR_1->props.tse && VAR_1->props.cptse) {
net_tx_pkt_build_vheader(VAR_1->tx_pkt, true, true, VAR_1->props.mss);
net_tx_pkt_update_ip_checksums(VAR_1->tx_pkt);
e1000x_inc_reg_if_not_full(VAR_0->mac, TSCTC);
return;
}... | [
"FUNC_0(E1000ECore *VAR_0, struct e1000e_tx *VAR_1)\n{",
"if (VAR_1->props.tse && VAR_1->props.cptse) {",
"net_tx_pkt_build_vheader(VAR_1->tx_pkt, true, true, VAR_1->props.mss);",
"net_tx_pkt_update_ip_checksums(VAR_1->tx_pkt);",
"e1000x_inc_reg_if_not_full(VAR_0->mac, TSCTC);",
"return;",
"}",
"if (V... | [
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
]
] |
15,169 | static ssize_t proxy_pwritev(FsContext *ctx, V9fsFidOpenState *fs,
const struct iovec *iov,
int iovcnt, off_t offset)
{
ssize_t ret;
#ifdef CONFIG_PREADV
ret = pwritev(fs->fd, iov, iovcnt, offset);
#else
ret = lseek(fs->fd, offset, SEEK_SET... | false | qemu | 494a8ebe713055d3946183f4b395f85a18b43e9e | static ssize_t proxy_pwritev(FsContext *ctx, V9fsFidOpenState *fs,
const struct iovec *iov,
int iovcnt, off_t offset)
{
ssize_t ret;
#ifdef CONFIG_PREADV
ret = pwritev(fs->fd, iov, iovcnt, offset);
#else
ret = lseek(fs->fd, offset, SEEK_SET... | {
"code": [],
"line_no": []
} | static ssize_t FUNC_0(FsContext *ctx, V9fsFidOpenState *fs,
const struct iovec *iov,
int iovcnt, off_t offset)
{
ssize_t ret;
#ifdef CONFIG_PREADV
ret = pwritev(fs->fd, iov, iovcnt, offset);
#else
ret = lseek(fs->fd, offset, SEEK_SET);
... | [
"static ssize_t FUNC_0(FsContext *ctx, V9fsFidOpenState *fs,\nconst struct iovec *iov,\nint iovcnt, off_t offset)\n{",
"ssize_t ret;",
"#ifdef CONFIG_PREADV\nret = pwritev(fs->fd, iov, iovcnt, offset);",
"#else\nret = lseek(fs->fd, offset, SEEK_SET);",
"if (ret >= 0) {",
"ret = writev(fs->fd, iov, iovcnt)... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5,
7
],
[
9
],
[
13,
15
],
[
17,
19
],
[
21
],
[
23
],
[
25
],
[
27,
29,
31
],
[
43,
45
],
[
47
],
[
49,
51
],
[
53
]
] |
15,170 | static int ppc6xx_tlb_check (CPUState *env, mmu_ctx_t *ctx,
target_ulong eaddr, int rw, int access_type)
{
ppc6xx_tlb_t *tlb;
int nr, best, way;
int ret;
best = -1;
ret = -1; /* No TLB found */
for (way = 0; way < env->nb_ways; way++) {
nr = ppc6xx... | false | qemu | b227a8e9aa5f27d29f77ba90d5eb9d0662a1175e | static int ppc6xx_tlb_check (CPUState *env, mmu_ctx_t *ctx,
target_ulong eaddr, int rw, int access_type)
{
ppc6xx_tlb_t *tlb;
int nr, best, way;
int ret;
best = -1;
ret = -1;
for (way = 0; way < env->nb_ways; way++) {
nr = ppc6xx_tlb_getnum(env, e... | {
"code": [],
"line_no": []
} | static int FUNC_0 (CPUState *VAR_0, mmu_ctx_t *VAR_1,
target_ulong VAR_2, int VAR_3, int VAR_4)
{
ppc6xx_tlb_t *tlb;
int VAR_5, VAR_6, VAR_7;
int VAR_8;
VAR_6 = -1;
VAR_8 = -1;
for (VAR_7 = 0; VAR_7 < VAR_0->nb_ways; VAR_7++) {
VAR_5 = ppc6xx_tlb_... | [
"static int FUNC_0 (CPUState *VAR_0, mmu_ctx_t *VAR_1,\ntarget_ulong VAR_2, int VAR_3, int VAR_4)\n{",
"ppc6xx_tlb_t *tlb;",
"int VAR_5, VAR_6, VAR_7;",
"int VAR_8;",
"VAR_6 = -1;",
"VAR_8 = -1;",
"for (VAR_7 = 0; VAR_7 < VAR_0->nb_ways; VAR_7++) {",
"VAR_5 = ppc6xx_tlb_getnum(VAR_0, VAR_2, VAR_7,\nVA... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
29
],
[
31,
33
],
[
35,
37,
39,
41,
43
],
[
45
],
[
47,
49
],
[
51
],
[
53,... |
15,171 | static inline bool media_is_dvd(SCSIDiskState *s)
{
uint64_t nb_sectors;
if (s->qdev.type != TYPE_ROM) {
return false;
}
if (!bdrv_is_inserted(s->qdev.conf.bs)) {
return false;
}
bdrv_get_geometry(s->qdev.conf.bs, &nb_sectors);
return nb_sectors > CD_MAX_SECTORS;
}... | false | qemu | 4be746345f13e99e468c60acbd3a355e8183e3ce | static inline bool media_is_dvd(SCSIDiskState *s)
{
uint64_t nb_sectors;
if (s->qdev.type != TYPE_ROM) {
return false;
}
if (!bdrv_is_inserted(s->qdev.conf.bs)) {
return false;
}
bdrv_get_geometry(s->qdev.conf.bs, &nb_sectors);
return nb_sectors > CD_MAX_SECTORS;
}... | {
"code": [],
"line_no": []
} | static inline bool FUNC_0(SCSIDiskState *s)
{
uint64_t nb_sectors;
if (s->qdev.type != TYPE_ROM) {
return false;
}
if (!bdrv_is_inserted(s->qdev.conf.bs)) {
return false;
}
bdrv_get_geometry(s->qdev.conf.bs, &nb_sectors);
return nb_sectors > CD_MAX_SECTORS;
}
| [
"static inline bool FUNC_0(SCSIDiskState *s)\n{",
"uint64_t nb_sectors;",
"if (s->qdev.type != TYPE_ROM) {",
"return false;",
"}",
"if (!bdrv_is_inserted(s->qdev.conf.bs)) {",
"return false;",
"}",
"bdrv_get_geometry(s->qdev.conf.bs, &nb_sectors);",
"return nb_sectors > CD_MAX_SECTORS;",
"}"
] | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
]
] |
15,174 | int avpriv_exif_decode_ifd(AVCodecContext *avctx, GetByteContext *gbytes, int le,
int depth, AVDictionary **metadata)
{
int i, ret;
int entries;
entries = ff_tget_short(gbytes, le);
if (bytestream2_get_bytes_left(gbytes) < entries * 12) {
return AVERROR_INVA... | false | FFmpeg | ce87711df563a9d2d0537a062b86bb91b15ea1a0 | int avpriv_exif_decode_ifd(AVCodecContext *avctx, GetByteContext *gbytes, int le,
int depth, AVDictionary **metadata)
{
int i, ret;
int entries;
entries = ff_tget_short(gbytes, le);
if (bytestream2_get_bytes_left(gbytes) < entries * 12) {
return AVERROR_INVA... | {
"code": [],
"line_no": []
} | int FUNC_0(AVCodecContext *VAR_0, GetByteContext *VAR_1, int VAR_2,
int VAR_3, AVDictionary **VAR_4)
{
int VAR_5, VAR_6;
int VAR_7;
VAR_7 = ff_tget_short(VAR_1, VAR_2);
if (bytestream2_get_bytes_left(VAR_1) < VAR_7 * 12) {
return AVERROR_INVALIDDATA;
}
... | [
"int FUNC_0(AVCodecContext *VAR_0, GetByteContext *VAR_1, int VAR_2,\nint VAR_3, AVDictionary **VAR_4)\n{",
"int VAR_5, VAR_6;",
"int VAR_7;",
"VAR_7 = ff_tget_short(VAR_1, VAR_2);",
"if (bytestream2_get_bytes_left(VAR_1) < VAR_7 * 12) {",
"return AVERROR_INVALIDDATA;",
"}",
"for (VAR_5 = 0; VAR_5 < V... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
13
],
[
17
],
[
19
],
[
21
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
39
],
[
41
]
] |
15,175 | DeviceState *qdev_create(BusState *bus, const char *name)
{
DeviceType *t;
DeviceState *dev;
for (t = device_type_list; t; t = t->next) {
if (strcmp(t->info->name, name) == 0) {
break;
}
}
if (!t) {
hw_error("Unknown device '%s'\n", name);
}
... | false | qemu | 10c4c98ab7dc18169b37b76f6ea5e60ebe65222b | DeviceState *qdev_create(BusState *bus, const char *name)
{
DeviceType *t;
DeviceState *dev;
for (t = device_type_list; t; t = t->next) {
if (strcmp(t->info->name, name) == 0) {
break;
}
}
if (!t) {
hw_error("Unknown device '%s'\n", name);
}
... | {
"code": [],
"line_no": []
} | DeviceState *FUNC_0(BusState *bus, const char *name)
{
DeviceType *t;
DeviceState *dev;
for (t = device_type_list; t; t = t->next) {
if (strcmp(t->info->name, name) == 0) {
break;
}
}
if (!t) {
hw_error("Unknown device '%s'\n", name);
}
dev... | [
"DeviceState *FUNC_0(BusState *bus, const char *name)\n{",
"DeviceType *t;",
"DeviceState *dev;",
"for (t = device_type_list; t; t = t->next) {",
"if (strcmp(t->info->name, name) == 0) {",
"break;",
"}",
"}",
"if (!t) {",
"hw_error(\"Unknown device '%s'\\n\", name);",
"}",
"dev = qemu_mallocz(... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
29
],
[
31
],
[
35
],
[
39
],
[
41,
43
],
[
45
],
[
47
],
[
49
],
... |
15,177 | static CPAccessResult ats_access(CPUARMState *env, const ARMCPRegInfo *ri)
{
if (ri->opc2 & 4) {
/* Other states are only available with TrustZone; in
* a non-TZ implementation these registers don't exist
* at all, which is an Uncategorized trap. This underdecoding
* is safe... | false | qemu | 7a0e58fa648736a75f2a6943afd2ab08ea15b8e0 | static CPAccessResult ats_access(CPUARMState *env, const ARMCPRegInfo *ri)
{
if (ri->opc2 & 4) {
return CP_ACCESS_TRAP_UNCATEGORIZED;
}
return CP_ACCESS_OK;
}
| {
"code": [],
"line_no": []
} | static CPAccessResult FUNC_0(CPUARMState *env, const ARMCPRegInfo *ri)
{
if (ri->opc2 & 4) {
return CP_ACCESS_TRAP_UNCATEGORIZED;
}
return CP_ACCESS_OK;
}
| [
"static CPAccessResult FUNC_0(CPUARMState *env, const ARMCPRegInfo *ri)\n{",
"if (ri->opc2 & 4) {",
"return CP_ACCESS_TRAP_UNCATEGORIZED;",
"}",
"return CP_ACCESS_OK;",
"}"
] | [
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
17
],
[
19
],
[
21
],
[
23
]
] |
15,178 | on_host_init(VSCMsgHeader *mhHeader, VSCMsgInit *incoming)
{
uint32_t *capabilities = (incoming->capabilities);
int num_capabilities =
1 + ((mhHeader->length - sizeof(VSCMsgInit)) / sizeof(uint32_t));
int i;
QemuThread thread_id;
incoming->version = ntohl(incoming->version);
if... | false | qemu | 2a0c46da967e5dc8cfe73b1b6fe7a1600c04f461 | on_host_init(VSCMsgHeader *mhHeader, VSCMsgInit *incoming)
{
uint32_t *capabilities = (incoming->capabilities);
int num_capabilities =
1 + ((mhHeader->length - sizeof(VSCMsgInit)) / sizeof(uint32_t));
int i;
QemuThread thread_id;
incoming->version = ntohl(incoming->version);
if... | {
"code": [],
"line_no": []
} | FUNC_0(VSCMsgHeader *VAR_0, VSCMsgInit *VAR_1)
{
uint32_t *capabilities = (VAR_1->capabilities);
int VAR_2 =
1 + ((VAR_0->length - sizeof(VSCMsgInit)) / sizeof(uint32_t));
int VAR_3;
QemuThread thread_id;
VAR_1->version = ntohl(VAR_1->version);
if (VAR_1->version != VSCARD_VERS... | [
"FUNC_0(VSCMsgHeader *VAR_0, VSCMsgInit *VAR_1)\n{",
"uint32_t *capabilities = (VAR_1->capabilities);",
"int VAR_2 =\n1 + ((VAR_0->length - sizeof(VSCMsgInit)) / sizeof(uint32_t));",
"int VAR_3;",
"QemuThread thread_id;",
"VAR_1->version = ntohl(VAR_1->version);",
"if (VAR_1->version != VSCARD_VERSION) ... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7,
9
],
[
11
],
[
13
],
[
17
],
[
19
],
[
21
],
[
23,
25
],
[
27
],
[
29
],
[
31
],
[
33,
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[... |
15,180 | static GenericList *qmp_input_next_list(Visitor *v, GenericList *tail,
size_t size)
{
QmpInputVisitor *qiv = to_qiv(v);
StackObject *so = &qiv->stack[qiv->nb_stack - 1];
if (!so->entry) {
return NULL;
}
tail->next = g_malloc0(size);
retu... | false | qemu | 3d344c2aabb7bc9b414321e3c52872901edebdda | static GenericList *qmp_input_next_list(Visitor *v, GenericList *tail,
size_t size)
{
QmpInputVisitor *qiv = to_qiv(v);
StackObject *so = &qiv->stack[qiv->nb_stack - 1];
if (!so->entry) {
return NULL;
}
tail->next = g_malloc0(size);
retu... | {
"code": [],
"line_no": []
} | static GenericList *FUNC_0(Visitor *v, GenericList *tail,
size_t size)
{
QmpInputVisitor *qiv = to_qiv(v);
StackObject *so = &qiv->stack[qiv->nb_stack - 1];
if (!so->entry) {
return NULL;
}
tail->next = g_malloc0(size);
return tail->next... | [
"static GenericList *FUNC_0(Visitor *v, GenericList *tail,\nsize_t size)\n{",
"QmpInputVisitor *qiv = to_qiv(v);",
"StackObject *so = &qiv->stack[qiv->nb_stack - 1];",
"if (!so->entry) {",
"return NULL;",
"}",
"tail->next = g_malloc0(size);",
"return tail->next;",
"}"
] | [
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
]
] |
15,181 | static size_t handle_aiocb_ioctl(struct qemu_paiocb *aiocb)
{
int ret;
ret = ioctl(aiocb->aio_fildes, aiocb->aio_ioctl_cmd, aiocb->aio_ioctl_buf);
if (ret == -1)
return -errno;
/*
* This looks weird, but the aio code only consideres a request
* successfull if it has written the number full number ... | false | qemu | 6769da29c7a3caa9de4020db87f495de692cf8e2 | static size_t handle_aiocb_ioctl(struct qemu_paiocb *aiocb)
{
int ret;
ret = ioctl(aiocb->aio_fildes, aiocb->aio_ioctl_cmd, aiocb->aio_ioctl_buf);
if (ret == -1)
return -errno;
return aiocb->aio_nbytes;
}
| {
"code": [],
"line_no": []
} | static size_t FUNC_0(struct qemu_paiocb *aiocb)
{
int VAR_0;
VAR_0 = ioctl(aiocb->aio_fildes, aiocb->aio_ioctl_cmd, aiocb->aio_ioctl_buf);
if (VAR_0 == -1)
return -errno;
return aiocb->aio_nbytes;
}
| [
"static size_t FUNC_0(struct qemu_paiocb *aiocb)\n{",
"int VAR_0;",
"VAR_0 = ioctl(aiocb->aio_fildes, aiocb->aio_ioctl_cmd, aiocb->aio_ioctl_buf);",
"if (VAR_0 == -1)\nreturn -errno;",
"return aiocb->aio_nbytes;",
"}"
] | [
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11,
13
],
[
33
],
[
35
]
] |
15,182 | static always_inline void gen_load_mem (DisasContext *ctx,
void (*tcg_gen_qemu_load)(TCGv t0, TCGv t1, int flags),
int ra, int rb, int32_t disp16,
int fp, int clear)
{
TCGv addr;
if (u... | false | qemu | a7812ae412311d7d47f8aa85656faadac9d64b56 | static always_inline void gen_load_mem (DisasContext *ctx,
void (*tcg_gen_qemu_load)(TCGv t0, TCGv t1, int flags),
int ra, int rb, int32_t disp16,
int fp, int clear)
{
TCGv addr;
if (u... | {
"code": [],
"line_no": []
} | static always_inline void FUNC_0 (DisasContext *ctx,
void (*tcg_gen_qemu_load)(TCGv t0, TCGv t1, int flags),
int ra, int rb, int32_t disp16,
int fp, int clear)
{
TCGv addr;
if (unlikel... | [
"static always_inline void FUNC_0 (DisasContext *ctx,\nvoid (*tcg_gen_qemu_load)(TCGv t0, TCGv t1, int flags),\nint ra, int rb, int32_t disp16,\nint fp, int clear)\n{",
"TCGv addr;",
"if (unlikely(ra == 31))\nreturn;",
"addr = tcg_temp_new(TCG_TYPE_I64);",
"if (rb != 31) {",
"tcg_gen_addi_i64(addr, cpu_ir... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5,
7,
9
],
[
11
],
[
15,
17
],
[
21
],
[
23
],
[
25
],
[
27,
29
],
[
31
],
[
33,
35
],
[
37
],
[
39
],
[
41,
43
],
[
45,
47
],
[
49
],
[
51
]
] |
15,184 | int cpu_watchpoint_remove(CPUState *env, target_ulong addr, target_ulong len,
int flags)
{
target_ulong len_mask = ~(len - 1);
CPUWatchpoint *wp;
TAILQ_FOREACH(wp, &env->watchpoints, entry) {
if (addr == wp->vaddr && len_mask == wp->len_mask
&& flag... | false | qemu | 72cf2d4f0e181d0d3a3122e04129c58a95da713e | int cpu_watchpoint_remove(CPUState *env, target_ulong addr, target_ulong len,
int flags)
{
target_ulong len_mask = ~(len - 1);
CPUWatchpoint *wp;
TAILQ_FOREACH(wp, &env->watchpoints, entry) {
if (addr == wp->vaddr && len_mask == wp->len_mask
&& flag... | {
"code": [],
"line_no": []
} | int FUNC_0(CPUState *VAR_0, target_ulong VAR_1, target_ulong VAR_2,
int VAR_3)
{
target_ulong len_mask = ~(VAR_2 - 1);
CPUWatchpoint *wp;
TAILQ_FOREACH(wp, &VAR_0->watchpoints, entry) {
if (VAR_1 == wp->vaddr && len_mask == wp->len_mask
&& VAR_3 == ... | [
"int FUNC_0(CPUState *VAR_0, target_ulong VAR_1, target_ulong VAR_2,\nint VAR_3)\n{",
"target_ulong len_mask = ~(VAR_2 - 1);",
"CPUWatchpoint *wp;",
"TAILQ_FOREACH(wp, &VAR_0->watchpoints, entry) {",
"if (VAR_1 == wp->vaddr && len_mask == wp->len_mask\n&& VAR_3 == (wp->VAR_3 & ~BP_WATCHPOINT_HIT)) {",
"cp... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
13
],
[
15,
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
]
] |
15,185 | static int segment_start(AVFormatContext *s, int write_header)
{
SegmentContext *c = s->priv_data;
AVFormatContext *oc = c->avf;
int err = 0;
if (write_header) {
avformat_free_context(oc);
c->avf = NULL;
if ((err = segment_mux_init(s)) < 0)
return err;
... | false | FFmpeg | 9f61abc8111c7c43f49ca012e957a108b9cc7610 | static int segment_start(AVFormatContext *s, int write_header)
{
SegmentContext *c = s->priv_data;
AVFormatContext *oc = c->avf;
int err = 0;
if (write_header) {
avformat_free_context(oc);
c->avf = NULL;
if ((err = segment_mux_init(s)) < 0)
return err;
... | {
"code": [],
"line_no": []
} | static int FUNC_0(AVFormatContext *VAR_0, int VAR_1)
{
SegmentContext *c = VAR_0->priv_data;
AVFormatContext *oc = c->avf;
int VAR_2 = 0;
if (VAR_1) {
avformat_free_context(oc);
c->avf = NULL;
if ((VAR_2 = segment_mux_init(VAR_0)) < 0)
return VAR_2;
... | [
"static int FUNC_0(AVFormatContext *VAR_0, int VAR_1)\n{",
"SegmentContext *c = VAR_0->priv_data;",
"AVFormatContext *oc = c->avf;",
"int VAR_2 = 0;",
"if (VAR_1) {",
"avformat_free_context(oc);",
"c->avf = NULL;",
"if ((VAR_2 = segment_mux_init(VAR_0)) < 0)\nreturn VAR_2;",
"oc = c->avf;",
"}",
... | [
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
],
[
35,
37,
39
],
[
43,
45,
47
],
[
51,
53
],
[
57
],
[
59,
61
... |
15,186 | static void s390x_cpu_set_id(Object *obj, Visitor *v, const char *name,
void *opaque, Error **errp)
{
S390CPU *cpu = S390_CPU(obj);
DeviceState *dev = DEVICE(obj);
const int64_t min = 0;
const int64_t max = UINT32_MAX;
Error *err = NULL;
int64_t value;
... | false | qemu | ca5c1457d614fec718aaec7bdf3663dec37e1e50 | static void s390x_cpu_set_id(Object *obj, Visitor *v, const char *name,
void *opaque, Error **errp)
{
S390CPU *cpu = S390_CPU(obj);
DeviceState *dev = DEVICE(obj);
const int64_t min = 0;
const int64_t max = UINT32_MAX;
Error *err = NULL;
int64_t value;
... | {
"code": [],
"line_no": []
} | static void FUNC_0(Object *VAR_0, Visitor *VAR_1, const char *VAR_2,
void *VAR_3, Error **VAR_4)
{
S390CPU *cpu = S390_CPU(VAR_0);
DeviceState *dev = DEVICE(VAR_0);
const int64_t VAR_5 = 0;
const int64_t VAR_6 = UINT32_MAX;
Error *err = NULL;
int64_t value;
... | [
"static void FUNC_0(Object *VAR_0, Visitor *VAR_1, const char *VAR_2,\nvoid *VAR_3, Error **VAR_4)\n{",
"S390CPU *cpu = S390_CPU(VAR_0);",
"DeviceState *dev = DEVICE(VAR_0);",
"const int64_t VAR_5 = 0;",
"const int64_t VAR_6 = UINT32_MAX;",
"Error *err = NULL;",
"int64_t value;",
"if (dev->realized) {... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
21
],
[
23,
25
],
[
27
],
[
29
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45,
47,
49
... |
15,188 | static void sunmouse_event(void *opaque,
int dx, int dy, int dz, int buttons_state)
{
ChannelState *s = opaque;
int ch;
MS_DPRINTF("dx=%d dy=%d buttons=%01x\n", dx, dy, buttons_state);
ch = 0x80 | 0x7; /* protocol start byte, no buttons pressed */
if (butt... | false | qemu | a0d98a712fbb1f22e347299006e4004bb985eb34 | static void sunmouse_event(void *opaque,
int dx, int dy, int dz, int buttons_state)
{
ChannelState *s = opaque;
int ch;
MS_DPRINTF("dx=%d dy=%d buttons=%01x\n", dx, dy, buttons_state);
ch = 0x80 | 0x7;
if (buttons_state & MOUSE_EVENT_LBUTTON)
ch ... | {
"code": [],
"line_no": []
} | static void FUNC_0(void *VAR_0,
int VAR_1, int VAR_2, int VAR_3, int VAR_4)
{
ChannelState *s = VAR_0;
int VAR_5;
MS_DPRINTF("VAR_1=%d VAR_2=%d buttons=%01x\n", VAR_1, VAR_2, VAR_4);
VAR_5 = 0x80 | 0x7;
if (VAR_4 & MOUSE_EVENT_LBUTTON)
VAR_5 ^= 0... | [
"static void FUNC_0(void *VAR_0,\nint VAR_1, int VAR_2, int VAR_3, int VAR_4)\n{",
"ChannelState *s = VAR_0;",
"int VAR_5;",
"MS_DPRINTF(\"VAR_1=%d VAR_2=%d buttons=%01x\\n\", VAR_1, VAR_2, VAR_4);",
"VAR_5 = 0x80 | 0x7;",
"if (VAR_4 & MOUSE_EVENT_LBUTTON)\nVAR_5 ^= 0x4;",
"if (VAR_4 & MOUSE_EVENT_MBUTT... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
13
],
[
17
],
[
21,
23
],
[
25,
27
],
[
29,
31
],
[
35
],
[
39
],
[
43,
45
],
[
47,
49
],
[
53
],
[
57
],
[
61,
63
],
[
65,
67
... |
15,189 | void bdrv_dirty_bitmap_serialize_part(const BdrvDirtyBitmap *bitmap,
uint8_t *buf, uint64_t start,
uint64_t count)
{
hbitmap_serialize_part(bitmap->bitmap, buf, start, count);
}
| false | qemu | 86f6ae67e157362f3b141649874213ce01dcc622 | void bdrv_dirty_bitmap_serialize_part(const BdrvDirtyBitmap *bitmap,
uint8_t *buf, uint64_t start,
uint64_t count)
{
hbitmap_serialize_part(bitmap->bitmap, buf, start, count);
}
| {
"code": [],
"line_no": []
} | void FUNC_0(const BdrvDirtyBitmap *VAR_0,
uint8_t *VAR_1, uint64_t VAR_2,
uint64_t VAR_3)
{
hbitmap_serialize_part(VAR_0->VAR_0, VAR_1, VAR_2, VAR_3);
}
| [
"void FUNC_0(const BdrvDirtyBitmap *VAR_0,\nuint8_t *VAR_1, uint64_t VAR_2,\nuint64_t VAR_3)\n{",
"hbitmap_serialize_part(VAR_0->VAR_0, VAR_1, VAR_2, VAR_3);",
"}"
] | [
0,
0,
0
] | [
[
1,
3,
5,
7
],
[
9
],
[
11
]
] |
15,190 | int nbd_init(int fd, QIOChannelSocket *sioc, NBDExportInfo *info,
Error **errp)
{
unsigned long sectors = info->size / BDRV_SECTOR_SIZE;
if (info->size / BDRV_SECTOR_SIZE != sectors) {
error_setg(errp, "Export size %" PRIu64 " too large for 32-bit kernel",
info->siz... | false | qemu | 081dd1fe36f0ccc04130d1edd136c787c5f8cc50 | int nbd_init(int fd, QIOChannelSocket *sioc, NBDExportInfo *info,
Error **errp)
{
unsigned long sectors = info->size / BDRV_SECTOR_SIZE;
if (info->size / BDRV_SECTOR_SIZE != sectors) {
error_setg(errp, "Export size %" PRIu64 " too large for 32-bit kernel",
info->siz... | {
"code": [],
"line_no": []
} | int FUNC_0(int VAR_0, QIOChannelSocket *VAR_1, NBDExportInfo *VAR_2,
Error **VAR_3)
{
unsigned long VAR_4 = VAR_2->size / BDRV_SECTOR_SIZE;
if (VAR_2->size / BDRV_SECTOR_SIZE != VAR_4) {
error_setg(VAR_3, "Export size %" PRIu64 " too large for 32-bit kernel",
VAR_2-... | [
"int FUNC_0(int VAR_0, QIOChannelSocket *VAR_1, NBDExportInfo *VAR_2,\nError **VAR_3)\n{",
"unsigned long VAR_4 = VAR_2->size / BDRV_SECTOR_SIZE;",
"if (VAR_2->size / BDRV_SECTOR_SIZE != VAR_4) {",
"error_setg(VAR_3, \"Export size %\" PRIu64 \" too large for 32-bit kernel\",\nVAR_2->size);",
"return -E2BIG;... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11,
13
],
[
15
],
[
17
],
[
21
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
37
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49
],
[
53
... |
15,192 | void helper_dcbz(CPUPPCState *env, target_ulong addr, uint32_t is_dcbzl)
{
int dcbz_size = env->dcache_line_size;
#if !defined(CONFIG_USER_ONLY) && defined(TARGET_PPC64)
if (!is_dcbzl &&
(env->excp_model == POWERPC_EXCP_970) &&
((env->spr[SPR_970_HID5] >> 7) & 0x3) == 1) {
dcbz_... | false | qemu | 414f5d1448fef9aad6d37f1d40d1158396573447 | void helper_dcbz(CPUPPCState *env, target_ulong addr, uint32_t is_dcbzl)
{
int dcbz_size = env->dcache_line_size;
#if !defined(CONFIG_USER_ONLY) && defined(TARGET_PPC64)
if (!is_dcbzl &&
(env->excp_model == POWERPC_EXCP_970) &&
((env->spr[SPR_970_HID5] >> 7) & 0x3) == 1) {
dcbz_... | {
"code": [],
"line_no": []
} | void FUNC_0(CPUPPCState *VAR_0, target_ulong VAR_1, uint32_t VAR_2)
{
int VAR_3 = VAR_0->dcache_line_size;
#if !defined(CONFIG_USER_ONLY) && defined(TARGET_PPC64)
if (!VAR_2 &&
(VAR_0->excp_model == POWERPC_EXCP_970) &&
((VAR_0->spr[SPR_970_HID5] >> 7) & 0x3) == 1) {
VAR_3 = 32;... | [
"void FUNC_0(CPUPPCState *VAR_0, target_ulong VAR_1, uint32_t VAR_2)\n{",
"int VAR_3 = VAR_0->dcache_line_size;",
"#if !defined(CONFIG_USER_ONLY) && defined(TARGET_PPC64)\nif (!VAR_2 &&\n(VAR_0->excp_model == POWERPC_EXCP_970) &&\n((VAR_0->spr[SPR_970_HID5] >> 7) & 0x3) == 1) {",
"VAR_3 = 32;",
"}",
"#end... | [
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9,
11,
13,
15
],
[
17
],
[
19
],
[
21,
29
],
[
31
]
] |
15,193 | static void nvme_rw_cb(void *opaque, int ret)
{
NvmeRequest *req = opaque;
NvmeSQueue *sq = req->sq;
NvmeCtrl *n = sq->ctrl;
NvmeCQueue *cq = n->cq[sq->cqid];
block_acct_done(bdrv_get_stats(n->conf.bs), &req->acct);
if (!ret) {
req->status = NVME_SUCCESS;
} else {
... | false | qemu | 4be746345f13e99e468c60acbd3a355e8183e3ce | static void nvme_rw_cb(void *opaque, int ret)
{
NvmeRequest *req = opaque;
NvmeSQueue *sq = req->sq;
NvmeCtrl *n = sq->ctrl;
NvmeCQueue *cq = n->cq[sq->cqid];
block_acct_done(bdrv_get_stats(n->conf.bs), &req->acct);
if (!ret) {
req->status = NVME_SUCCESS;
} else {
... | {
"code": [],
"line_no": []
} | static void FUNC_0(void *VAR_0, int VAR_1)
{
NvmeRequest *req = VAR_0;
NvmeSQueue *sq = req->sq;
NvmeCtrl *n = sq->ctrl;
NvmeCQueue *cq = n->cq[sq->cqid];
block_acct_done(bdrv_get_stats(n->conf.bs), &req->acct);
if (!VAR_1) {
req->status = NVME_SUCCESS;
} else {
r... | [
"static void FUNC_0(void *VAR_0, int VAR_1)\n{",
"NvmeRequest *req = VAR_0;",
"NvmeSQueue *sq = req->sq;",
"NvmeCtrl *n = sq->ctrl;",
"NvmeCQueue *cq = n->cq[sq->cqid];",
"block_acct_done(bdrv_get_stats(n->conf.bs), &req->acct);",
"if (!VAR_1) {",
"req->status = NVME_SUCCESS;",
"} else {",
"req->s... | [
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
],
[
29
],
[
31
],
[
33
]
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.