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 |
|---|---|---|---|---|---|---|---|---|---|---|
10,704 | BlockDriverState *bdrv_find_node(const char *node_name)
{
BlockDriverState *bs;
assert(node_name);
QTAILQ_FOREACH(bs, &graph_bdrv_states, node_list) {
if (!strcmp(node_name, bs->node_name)) {
return bs;
}
}
return NULL;
}
| false | qemu | 61007b316cd71ee7333ff7a0a749a8949527575f | BlockDriverState *bdrv_find_node(const char *node_name)
{
BlockDriverState *bs;
assert(node_name);
QTAILQ_FOREACH(bs, &graph_bdrv_states, node_list) {
if (!strcmp(node_name, bs->node_name)) {
return bs;
}
}
return NULL;
}
| {
"code": [],
"line_no": []
} | BlockDriverState *FUNC_0(const char *node_name)
{
BlockDriverState *bs;
assert(node_name);
QTAILQ_FOREACH(bs, &graph_bdrv_states, node_list) {
if (!strcmp(node_name, bs->node_name)) {
return bs;
}
}
return NULL;
}
| [
"BlockDriverState *FUNC_0(const char *node_name)\n{",
"BlockDriverState *bs;",
"assert(node_name);",
"QTAILQ_FOREACH(bs, &graph_bdrv_states, node_list) {",
"if (!strcmp(node_name, bs->node_name)) {",
"return bs;",
"}",
"}",
"return NULL;",
"}"
] | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
]
] |
10,705 | static inline void load_seg_vm(int seg, int selector)
{
selector &= 0xffff;
cpu_x86_load_seg_cache(env, seg, selector,
(uint8_t *)(selector << 4), 0xffff, 0);
}
| false | qemu | 7e84c2498f0ff3999937d18d1e9abaa030400000 | static inline void load_seg_vm(int seg, int selector)
{
selector &= 0xffff;
cpu_x86_load_seg_cache(env, seg, selector,
(uint8_t *)(selector << 4), 0xffff, 0);
}
| {
"code": [],
"line_no": []
} | static inline void FUNC_0(int VAR_0, int VAR_1)
{
VAR_1 &= 0xffff;
cpu_x86_load_seg_cache(env, VAR_0, VAR_1,
(uint8_t *)(VAR_1 << 4), 0xffff, 0);
}
| [
"static inline void FUNC_0(int VAR_0, int VAR_1)\n{",
"VAR_1 &= 0xffff;",
"cpu_x86_load_seg_cache(env, VAR_0, VAR_1,\n(uint8_t *)(VAR_1 << 4), 0xffff, 0);",
"}"
] | [
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7,
9
],
[
11
]
] |
10,706 | static int ehci_state_fetchqtd(EHCIQueue *q, int async)
{
int again = 0;
get_dwords(NLPTR_GET(q->qtdaddr),(uint32_t *) &q->qtd, sizeof(EHCIqtd) >> 2);
ehci_trace_qtd(q, NLPTR_GET(q->qtdaddr), &q->qtd);
if (q->qtd.token & QTD_TOKEN_ACTIVE) {
ehci_set_state(q->ehci, async, EST_EXECUTE);
... | false | qemu | 68d553587c0aa271c3eb2902921b503740d775b6 | static int ehci_state_fetchqtd(EHCIQueue *q, int async)
{
int again = 0;
get_dwords(NLPTR_GET(q->qtdaddr),(uint32_t *) &q->qtd, sizeof(EHCIqtd) >> 2);
ehci_trace_qtd(q, NLPTR_GET(q->qtdaddr), &q->qtd);
if (q->qtd.token & QTD_TOKEN_ACTIVE) {
ehci_set_state(q->ehci, async, EST_EXECUTE);
... | {
"code": [],
"line_no": []
} | static int FUNC_0(EHCIQueue *VAR_0, int VAR_1)
{
int VAR_2 = 0;
get_dwords(NLPTR_GET(VAR_0->qtdaddr),(uint32_t *) &VAR_0->qtd, sizeof(EHCIqtd) >> 2);
ehci_trace_qtd(VAR_0, NLPTR_GET(VAR_0->qtdaddr), &VAR_0->qtd);
if (VAR_0->qtd.token & QTD_TOKEN_ACTIVE) {
ehci_set_state(VAR_0->ehci, VA... | [
"static int FUNC_0(EHCIQueue *VAR_0, int VAR_1)\n{",
"int VAR_2 = 0;",
"get_dwords(NLPTR_GET(VAR_0->qtdaddr),(uint32_t *) &VAR_0->qtd, sizeof(EHCIqtd) >> 2);",
"ehci_trace_qtd(VAR_0, NLPTR_GET(VAR_0->qtdaddr), &VAR_0->qtd);",
"if (VAR_0->qtd.token & QTD_TOKEN_ACTIVE) {",
"ehci_set_state(VAR_0->ehci, VAR_1... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
31
],
[
33
]
] |
10,707 | av_cold void ff_dnxhdenc_init_x86(DNXHDEncContext *ctx)
{
#if HAVE_SSE2_INLINE
if (av_get_cpu_flags() & AV_CPU_FLAG_SSE2) {
if (ctx->cid_table->bit_depth == 8)
ctx->get_pixels_8x4_sym = get_pixels_8x4_sym_sse2;
}
#endif /* HAVE_SSE2_INLINE */
}
| false | FFmpeg | 6369ba3c9cc74becfaad2a8882dff3dd3e7ae3c0 | av_cold void ff_dnxhdenc_init_x86(DNXHDEncContext *ctx)
{
#if HAVE_SSE2_INLINE
if (av_get_cpu_flags() & AV_CPU_FLAG_SSE2) {
if (ctx->cid_table->bit_depth == 8)
ctx->get_pixels_8x4_sym = get_pixels_8x4_sym_sse2;
}
#endif
}
| {
"code": [],
"line_no": []
} | av_cold void FUNC_0(DNXHDEncContext *ctx)
{
#if HAVE_SSE2_INLINE
if (av_get_cpu_flags() & AV_CPU_FLAG_SSE2) {
if (ctx->cid_table->bit_depth == 8)
ctx->get_pixels_8x4_sym = get_pixels_8x4_sym_sse2;
}
#endif
}
| [
"av_cold void FUNC_0(DNXHDEncContext *ctx)\n{",
"#if HAVE_SSE2_INLINE\nif (av_get_cpu_flags() & AV_CPU_FLAG_SSE2) {",
"if (ctx->cid_table->bit_depth == 8)\nctx->get_pixels_8x4_sym = get_pixels_8x4_sym_sse2;",
"}",
"#endif\n}"
] | [
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5,
7
],
[
9,
11
],
[
13
],
[
15,
17
]
] |
10,708 | static int usb_bt_initfn(USBDevice *dev)
{
struct USBBtState *s = DO_UPCAST(struct USBBtState, dev, dev);
s->dev.speed = USB_SPEED_HIGH;
return 0;
}
| false | qemu | a980a065fb5e86d6dec337e6cb6ff432f1a143c9 | static int usb_bt_initfn(USBDevice *dev)
{
struct USBBtState *s = DO_UPCAST(struct USBBtState, dev, dev);
s->dev.speed = USB_SPEED_HIGH;
return 0;
}
| {
"code": [],
"line_no": []
} | static int FUNC_0(USBDevice *VAR_0)
{
struct USBBtState *VAR_1 = DO_UPCAST(struct USBBtState, VAR_0, VAR_0);
VAR_1->VAR_0.speed = USB_SPEED_HIGH;
return 0;
}
| [
"static int FUNC_0(USBDevice *VAR_0)\n{",
"struct USBBtState *VAR_1 = DO_UPCAST(struct USBBtState, VAR_0, VAR_0);",
"VAR_1->VAR_0.speed = USB_SPEED_HIGH;",
"return 0;",
"}"
] | [
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
]
] |
10,709 | static void ppc_hash64_set_dsi(CPUState *cs, CPUPPCState *env, uint64_t dar,
uint64_t dsisr)
{
bool vpm;
if (msr_dr) {
vpm = !!(env->spr[SPR_LPCR] & LPCR_VPM1);
} else {
vpm = !!(env->spr[SPR_LPCR] & LPCR_VPM0);
}
if (vpm && !msr_hv) {
... | false | qemu | 506590836144af7d0de3fc4c691bb5ed49d41645 | static void ppc_hash64_set_dsi(CPUState *cs, CPUPPCState *env, uint64_t dar,
uint64_t dsisr)
{
bool vpm;
if (msr_dr) {
vpm = !!(env->spr[SPR_LPCR] & LPCR_VPM1);
} else {
vpm = !!(env->spr[SPR_LPCR] & LPCR_VPM0);
}
if (vpm && !msr_hv) {
... | {
"code": [],
"line_no": []
} | static void FUNC_0(CPUState *VAR_0, CPUPPCState *VAR_1, uint64_t VAR_2,
uint64_t VAR_3)
{
bool vpm;
if (msr_dr) {
vpm = !!(VAR_1->spr[SPR_LPCR] & LPCR_VPM1);
} else {
vpm = !!(VAR_1->spr[SPR_LPCR] & LPCR_VPM0);
}
if (vpm && !msr_hv) {
... | [
"static void FUNC_0(CPUState *VAR_0, CPUPPCState *VAR_1, uint64_t VAR_2,\nuint64_t VAR_3)\n{",
"bool vpm;",
"if (msr_dr) {",
"vpm = !!(VAR_1->spr[SPR_LPCR] & LPCR_VPM1);",
"} else {",
"vpm = !!(VAR_1->spr[SPR_LPCR] & LPCR_VPM0);",
"}",
"if (vpm && !msr_hv) {",
"VAR_0->exception_index = POWERPC_EXCP_... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
]
] |
10,710 | static void cpu_ppc_decr_cb(void *opaque)
{
PowerPCCPU *cpu = opaque;
_cpu_ppc_store_decr(cpu, 0x00000000, 0xFFFFFFFF, 1);
}
| false | qemu | e81a982aa5398269a2cc344091ffa4930bdd242f | static void cpu_ppc_decr_cb(void *opaque)
{
PowerPCCPU *cpu = opaque;
_cpu_ppc_store_decr(cpu, 0x00000000, 0xFFFFFFFF, 1);
}
| {
"code": [],
"line_no": []
} | static void FUNC_0(void *VAR_0)
{
PowerPCCPU *cpu = VAR_0;
_cpu_ppc_store_decr(cpu, 0x00000000, 0xFFFFFFFF, 1);
}
| [
"static void FUNC_0(void *VAR_0)\n{",
"PowerPCCPU *cpu = VAR_0;",
"_cpu_ppc_store_decr(cpu, 0x00000000, 0xFFFFFFFF, 1);",
"}"
] | [
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
]
] |
10,711 | static int vmdk_open_vmdk3(BlockDriverState *bs,
BlockDriverState *file,
int flags)
{
int ret;
uint32_t magic;
VMDK3Header header;
VmdkExtent *extent;
ret = bdrv_pread(file, sizeof(magic), &header, sizeof(header));
if (ret < 0) {
... | false | qemu | 8aa1331c09a9b899f48d97f097bb49b7d458be1c | static int vmdk_open_vmdk3(BlockDriverState *bs,
BlockDriverState *file,
int flags)
{
int ret;
uint32_t magic;
VMDK3Header header;
VmdkExtent *extent;
ret = bdrv_pread(file, sizeof(magic), &header, sizeof(header));
if (ret < 0) {
... | {
"code": [],
"line_no": []
} | static int FUNC_0(BlockDriverState *VAR_0,
BlockDriverState *VAR_1,
int VAR_2)
{
int VAR_3;
uint32_t magic;
VMDK3Header header;
VmdkExtent *extent;
VAR_3 = bdrv_pread(VAR_1, sizeof(magic), &header, sizeof(header));
if (VAR_3 < 0) {... | [
"static int FUNC_0(BlockDriverState *VAR_0,\nBlockDriverState *VAR_1,\nint VAR_2)\n{",
"int VAR_3;",
"uint32_t magic;",
"VMDK3Header header;",
"VmdkExtent *extent;",
"VAR_3 = bdrv_pread(VAR_1, sizeof(magic), &header, sizeof(header));",
"if (VAR_3 < 0) {",
"return VAR_3;",
"}",
"extent = vmdk_add_e... | [
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
],
[
45
],
[
47
],
[
49
],
[
51
]
] |
10,712 | static uint64_t mv88w8618_flashcfg_read(void *opaque,
target_phys_addr_t offset,
unsigned size)
{
mv88w8618_flashcfg_state *s = opaque;
switch (offset) {
case MP_FLASHCFG_CFGR0:
return s->cfgr0;
default:
... | false | qemu | a8170e5e97ad17ca169c64ba87ae2f53850dab4c | static uint64_t mv88w8618_flashcfg_read(void *opaque,
target_phys_addr_t offset,
unsigned size)
{
mv88w8618_flashcfg_state *s = opaque;
switch (offset) {
case MP_FLASHCFG_CFGR0:
return s->cfgr0;
default:
... | {
"code": [],
"line_no": []
} | static uint64_t FUNC_0(void *opaque,
target_phys_addr_t offset,
unsigned size)
{
mv88w8618_flashcfg_state *s = opaque;
switch (offset) {
case MP_FLASHCFG_CFGR0:
return s->cfgr0;
default:
return 0... | [
"static uint64_t FUNC_0(void *opaque,\ntarget_phys_addr_t offset,\nunsigned size)\n{",
"mv88w8618_flashcfg_state *s = opaque;",
"switch (offset) {",
"case MP_FLASHCFG_CFGR0:\nreturn s->cfgr0;",
"default:\nreturn 0;",
"}",
"}"
] | [
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5,
7
],
[
9
],
[
13
],
[
15,
17
],
[
21,
23
],
[
25
],
[
27
]
] |
10,713 | static void qio_channel_socket_dgram_worker_free(gpointer opaque)
{
struct QIOChannelSocketDGramWorkerData *data = opaque;
qapi_free_SocketAddressLegacy(data->localAddr);
qapi_free_SocketAddressLegacy(data->remoteAddr);
g_free(data);
}
| false | qemu | bd269ebc82fbaa5fe7ce5bc7c1770ac8acecd884 | static void qio_channel_socket_dgram_worker_free(gpointer opaque)
{
struct QIOChannelSocketDGramWorkerData *data = opaque;
qapi_free_SocketAddressLegacy(data->localAddr);
qapi_free_SocketAddressLegacy(data->remoteAddr);
g_free(data);
}
| {
"code": [],
"line_no": []
} | static void FUNC_0(gpointer VAR_0)
{
struct QIOChannelSocketDGramWorkerData *VAR_1 = VAR_0;
qapi_free_SocketAddressLegacy(VAR_1->localAddr);
qapi_free_SocketAddressLegacy(VAR_1->remoteAddr);
g_free(VAR_1);
}
| [
"static void FUNC_0(gpointer VAR_0)\n{",
"struct QIOChannelSocketDGramWorkerData *VAR_1 = VAR_0;",
"qapi_free_SocketAddressLegacy(VAR_1->localAddr);",
"qapi_free_SocketAddressLegacy(VAR_1->remoteAddr);",
"g_free(VAR_1);",
"}"
] | [
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
]
] |
10,714 | static QString *qstring_from_escaped_str(JSONParserContext *ctxt, QObject *token)
{
const char *ptr = token_get_value(token);
QString *str;
int double_quote = 1;
if (*ptr == '"') {
double_quote = 1;
} else {
double_quote = 0;
}
ptr++;
str = qstring_new();
... | false | qemu | 9bada8971173345ceb37ed1a47b00a01a4dd48cf | static QString *qstring_from_escaped_str(JSONParserContext *ctxt, QObject *token)
{
const char *ptr = token_get_value(token);
QString *str;
int double_quote = 1;
if (*ptr == '"') {
double_quote = 1;
} else {
double_quote = 0;
}
ptr++;
str = qstring_new();
... | {
"code": [],
"line_no": []
} | static QString *FUNC_0(JSONParserContext *ctxt, QObject *token)
{
const char *VAR_0 = token_get_value(token);
QString *str;
int VAR_1 = 1;
if (*VAR_0 == '"') {
VAR_1 = 1;
} else {
VAR_1 = 0;
}
VAR_0++;
str = qstring_new();
while (*VAR_0 &&
... | [
"static QString *FUNC_0(JSONParserContext *ctxt, QObject *token)\n{",
"const char *VAR_0 = token_get_value(token);",
"QString *str;",
"int VAR_1 = 1;",
"if (*VAR_0 == '\"') {",
"VAR_1 = 1;",
"} else {",
"VAR_1 = 0;",
"}",
"VAR_0++;",
"str = qstring_new();",
"while (*VAR_0 &&\n((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,
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
],
[
39
],
[
41,
43
],
[
45
],
[
47
],
[
49,... |
10,715 | static void init_types(void)
{
static int inited;
int i;
if (inited) {
return;
}
for (i = 0; i < MODULE_INIT_MAX; i++) {
TAILQ_INIT(&init_type_list[i]);
}
inited = 1;
}
| false | qemu | 72cf2d4f0e181d0d3a3122e04129c58a95da713e | static void init_types(void)
{
static int inited;
int i;
if (inited) {
return;
}
for (i = 0; i < MODULE_INIT_MAX; i++) {
TAILQ_INIT(&init_type_list[i]);
}
inited = 1;
}
| {
"code": [],
"line_no": []
} | static void FUNC_0(void)
{
static int VAR_0;
int VAR_1;
if (VAR_0) {
return;
}
for (VAR_1 = 0; VAR_1 < MODULE_INIT_MAX; VAR_1++) {
TAILQ_INIT(&init_type_list[VAR_1]);
}
VAR_0 = 1;
}
| [
"static void FUNC_0(void)\n{",
"static int VAR_0;",
"int VAR_1;",
"if (VAR_0) {",
"return;",
"}",
"for (VAR_1 = 0; VAR_1 < MODULE_INIT_MAX; VAR_1++) {",
"TAILQ_INIT(&init_type_list[VAR_1]);",
"}",
"VAR_0 = 1;",
"}"
] | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
13
],
[
15
],
[
19
],
[
21
],
[
23
],
[
27
],
[
29
]
] |
10,716 | int qcow2_alloc_cluster_offset(BlockDriverState *bs, uint64_t offset,
int n_start, int n_end, int *num, QCowL2Meta *m)
{
BDRVQcowState *s = bs->opaque;
int l2_index, ret;
uint64_t l2_offset, *l2_table;
int64_t cluster_offset;
unsigned int nb_clusters, i = 0;
QCowL2Meta *old_alloc;
... | false | qemu | 05140499d38154df942048109ad78421ae3fd43a | int qcow2_alloc_cluster_offset(BlockDriverState *bs, uint64_t offset,
int n_start, int n_end, int *num, QCowL2Meta *m)
{
BDRVQcowState *s = bs->opaque;
int l2_index, ret;
uint64_t l2_offset, *l2_table;
int64_t cluster_offset;
unsigned int nb_clusters, i = 0;
QCowL2Meta *old_alloc;
... | {
"code": [],
"line_no": []
} | int FUNC_0(BlockDriverState *VAR_0, uint64_t VAR_1,
int VAR_2, int VAR_3, int *VAR_4, QCowL2Meta *VAR_5)
{
BDRVQcowState *s = VAR_0->opaque;
int VAR_6, VAR_7;
uint64_t l2_offset, *l2_table;
int64_t cluster_offset;
unsigned int VAR_8, VAR_9 = 0;
QCowL2Meta *old_alloc;
VAR_7 = g... | [
"int FUNC_0(BlockDriverState *VAR_0, uint64_t VAR_1,\nint VAR_2, int VAR_3, int *VAR_4, QCowL2Meta *VAR_5)\n{",
"BDRVQcowState *s = VAR_0->opaque;",
"int VAR_6, VAR_7;",
"uint64_t l2_offset, *l2_table;",
"int64_t cluster_offset;",
"unsigned int VAR_8, VAR_9 = 0;",
"QCowL2Meta *old_alloc;",
"VAR_7 = ge... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
31,
33
],
[
37
],
[
41
],
[
49
],
[
51,
53
],
[
57
],
[
59
],
[... |
10,717 | static void test_validate_union_native_list(TestInputVisitorData *data,
const void *unused)
{
UserDefNativeListUnion *tmp = NULL;
Visitor *v;
Error *err = NULL;
v = validate_test_init(data, "{ 'type': 'integer', 'data' : [ 1, 2 ] }");
visit_type... | false | qemu | 3f66f764ee25f10d3e1144ebc057a949421b7728 | static void test_validate_union_native_list(TestInputVisitorData *data,
const void *unused)
{
UserDefNativeListUnion *tmp = NULL;
Visitor *v;
Error *err = NULL;
v = validate_test_init(data, "{ 'type': 'integer', 'data' : [ 1, 2 ] }");
visit_type... | {
"code": [],
"line_no": []
} | static void FUNC_0(TestInputVisitorData *VAR_0,
const void *VAR_1)
{
UserDefNativeListUnion *tmp = NULL;
Visitor *v;
Error *err = NULL;
v = validate_test_init(VAR_0, "{ 'type': 'integer', 'VAR_0' : [ 1, 2 ] }");
visit_type_UserDefNativeListUnion... | [
"static void FUNC_0(TestInputVisitorData *VAR_0,\nconst void *VAR_1)\n{",
"UserDefNativeListUnion *tmp = NULL;",
"Visitor *v;",
"Error *err = NULL;",
"v = validate_test_init(VAR_0, \"{ 'type': 'integer', 'VAR_0' : [ 1, 2 ] }\");",
"visit_type_UserDefNativeListUnion(v, &tmp, NULL, &err);",
"g_assert(!err... | [
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
15
],
[
19
],
[
21
],
[
23
],
[
25
]
] |
10,718 | static int delta_decode(uint8_t *dst, const uint8_t *src, int src_size,
unsigned val, const int8_t *table)
{
uint8_t *dst0 = dst;
while (src_size--) {
uint8_t d = *src++;
val = av_clip_uint8(val + table[d & 0xF]);
*dst++ = val;
val = av_clip_uin... | false | FFmpeg | df824548d031dbfc5fa86ea9e0c652bd086b55c4 | static int delta_decode(uint8_t *dst, const uint8_t *src, int src_size,
unsigned val, const int8_t *table)
{
uint8_t *dst0 = dst;
while (src_size--) {
uint8_t d = *src++;
val = av_clip_uint8(val + table[d & 0xF]);
*dst++ = val;
val = av_clip_uin... | {
"code": [],
"line_no": []
} | static int FUNC_0(uint8_t *VAR_0, const uint8_t *VAR_1, int VAR_2,
unsigned VAR_3, const int8_t *VAR_4)
{
uint8_t *dst0 = VAR_0;
while (VAR_2--) {
uint8_t d = *VAR_1++;
VAR_3 = av_clip_uint8(VAR_3 + VAR_4[d & 0xF]);
*VAR_0++ = VAR_3;
VAR_3 = av_... | [
"static int FUNC_0(uint8_t *VAR_0, const uint8_t *VAR_1, int VAR_2,\nunsigned VAR_3, const int8_t *VAR_4)\n{",
"uint8_t *dst0 = VAR_0;",
"while (VAR_2--) {",
"uint8_t d = *VAR_1++;",
"VAR_3 = av_clip_uint8(VAR_3 + VAR_4[d & 0xF]);",
"*VAR_0++ = VAR_3;",
"VAR_3 = av_clip_uint8(VAR_3 + VAR_4[d >> 4]);",
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
27
],
[
29
]
] |
10,719 | int css_do_ssch(SubchDev *sch, ORB *orb)
{
SCSW *s = &sch->curr_status.scsw;
PMCW *p = &sch->curr_status.pmcw;
int ret;
if (!(p->flags & (PMCW_FLAGS_MASK_DNV | PMCW_FLAGS_MASK_ENA))) {
ret = -ENODEV;
goto out;
}
if (s->ctrl & SCSW_STCTL_STATUS_PEND) {
ret = ... | false | qemu | c679e74d2e29fa08ede9121d59aee4e9675611d7 | int css_do_ssch(SubchDev *sch, ORB *orb)
{
SCSW *s = &sch->curr_status.scsw;
PMCW *p = &sch->curr_status.pmcw;
int ret;
if (!(p->flags & (PMCW_FLAGS_MASK_DNV | PMCW_FLAGS_MASK_ENA))) {
ret = -ENODEV;
goto out;
}
if (s->ctrl & SCSW_STCTL_STATUS_PEND) {
ret = ... | {
"code": [],
"line_no": []
} | int FUNC_0(SubchDev *VAR_0, ORB *VAR_1)
{
SCSW *s = &VAR_0->curr_status.scsw;
PMCW *p = &VAR_0->curr_status.pmcw;
int VAR_2;
if (!(p->flags & (PMCW_FLAGS_MASK_DNV | PMCW_FLAGS_MASK_ENA))) {
VAR_2 = -ENODEV;
goto out;
}
if (s->ctrl & SCSW_STCTL_STATUS_PEND) {
... | [
"int FUNC_0(SubchDev *VAR_0, ORB *VAR_1)\n{",
"SCSW *s = &VAR_0->curr_status.scsw;",
"PMCW *p = &VAR_0->curr_status.pmcw;",
"int VAR_2;",
"if (!(p->flags & (PMCW_FLAGS_MASK_DNV | PMCW_FLAGS_MASK_ENA))) {",
"VAR_2 = -ENODEV;",
"goto out;",
"}",
"if (s->ctrl & SCSW_STCTL_STATUS_PEND) {",
"VAR_2 = -E... | [
0,
0,
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
],
[
23
],
[
25
],
[
27
],
[
29
],
[
33,
35,
37
],
[
39
],
[
41
],
[
43
],
[
49
],
[
51
],
[
53
... |
10,720 | static void ehci_reset(void *opaque)
{
EHCIState *s = opaque;
int i;
USBDevice *devs[NB_PORTS];
trace_usb_ehci_reset();
/*
* Do the detach before touching portsc, so that it correctly gets send to
* us or to our companion based on PORTSC_POWNER before the reset.
*/
f... | false | qemu | 891fb2cd4592b6fe76106a69e0ca40efbf82726a | static void ehci_reset(void *opaque)
{
EHCIState *s = opaque;
int i;
USBDevice *devs[NB_PORTS];
trace_usb_ehci_reset();
for(i = 0; i < NB_PORTS; i++) {
devs[i] = s->ports[i].dev;
if (devs[i]) {
usb_attach(&s->ports[i], NULL);
}
}
... | {
"code": [],
"line_no": []
} | static void FUNC_0(void *VAR_0)
{
EHCIState *s = VAR_0;
int VAR_1;
USBDevice *devs[NB_PORTS];
trace_usb_ehci_reset();
for(VAR_1 = 0; VAR_1 < NB_PORTS; VAR_1++) {
devs[VAR_1] = s->ports[VAR_1].dev;
if (devs[VAR_1]) {
usb_attach(&s->ports[VAR_1], NU... | [
"static void FUNC_0(void *VAR_0)\n{",
"EHCIState *s = VAR_0;",
"int VAR_1;",
"USBDevice *devs[NB_PORTS];",
"trace_usb_ehci_reset();",
"for(VAR_1 = 0; VAR_1 < NB_PORTS; VAR_1++) {",
"devs[VAR_1] = s->ports[VAR_1].dev;",
"if (devs[VAR_1]) {",
"usb_attach(&s->ports[VAR_1], NULL);",
"}",
"}",
"mem... | [
0,
0,
0,
0,
0,
0,
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
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
39
],
[
43
],
[
45
],
[
49
],
[
51
],
[
53
],
[
55
],
[
59
],
[
61
... |
10,724 | DISAS_INSN(divl)
{
TCGv num;
TCGv den;
TCGv reg;
uint16_t ext;
ext = read_im16(env, s);
if (ext & 0x87f8) {
gen_exception(s, s->pc - 4, EXCP_UNSUPPORTED);
return;
}
num = DREG(ext, 12);
reg = DREG(ext, 0);
tcg_gen_mov_i32(QREG_DIV1, num);
SRC_E... | true | qemu | 0ccb9c1d8128a020720d5c6abf99a470742a1b94 | DISAS_INSN(divl)
{
TCGv num;
TCGv den;
TCGv reg;
uint16_t ext;
ext = read_im16(env, s);
if (ext & 0x87f8) {
gen_exception(s, s->pc - 4, EXCP_UNSUPPORTED);
return;
}
num = DREG(ext, 12);
reg = DREG(ext, 0);
tcg_gen_mov_i32(QREG_DIV1, num);
SRC_E... | {
"code": [
" TCGv reg;",
" } else {",
" TCGv num;",
" TCGv den;",
" TCGv reg;",
" if (ext & 0x87f8) {",
" gen_exception(s, s->pc - 4, EXCP_UNSUPPORTED);",
" num = DREG(ext, 12);",
" reg = DREG(ext, 0);",
" tcg_gen_mov_i32(QREG_DIV1, num);",
... | FUNC_0(VAR_0)
{
TCGv num;
TCGv den;
TCGv reg;
uint16_t ext;
ext = read_im16(env, s);
if (ext & 0x87f8) {
gen_exception(s, s->pc - 4, EXCP_UNSUPPORTED);
return;
}
num = DREG(ext, 12);
reg = DREG(ext, 0);
tcg_gen_mov_i32(QREG_DIV1, num);
SRC_EA(e... | [
"FUNC_0(VAR_0)\n{",
"TCGv num;",
"TCGv den;",
"TCGv reg;",
"uint16_t ext;",
"ext = read_im16(env, s);",
"if (ext & 0x87f8) {",
"gen_exception(s, s->pc - 4, EXCP_UNSUPPORTED);",
"return;",
"}",
"num = DREG(ext, 12);",
"reg = DREG(ext, 0);",
"tcg_gen_mov_i32(QREG_DIV1, num);",
"SRC_EA(env, d... | [
0,
1,
1,
1,
0,
0,
1,
1,
0,
0,
1,
1,
1,
0,
1,
1,
1,
0,
1,
0,
1,
1,
0,
1,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
... |
10,725 | static void gen_dcbi(DisasContext *ctx)
{
#if defined(CONFIG_USER_ONLY)
gen_inval_exception(ctx, POWERPC_EXCP_PRIV_OPC);
#else
TCGv EA, val;
if (unlikely(ctx->pr)) {
gen_inval_exception(ctx, POWERPC_EXCP_PRIV_OPC);
return;
}
EA = tcg_temp_new();
gen_set_access_type(ctx... | true | qemu | 9b2fadda3e0196ffd485adde4fe9cdd6fae35300 | static void gen_dcbi(DisasContext *ctx)
{
#if defined(CONFIG_USER_ONLY)
gen_inval_exception(ctx, POWERPC_EXCP_PRIV_OPC);
#else
TCGv EA, val;
if (unlikely(ctx->pr)) {
gen_inval_exception(ctx, POWERPC_EXCP_PRIV_OPC);
return;
}
EA = tcg_temp_new();
gen_set_access_type(ctx... | {
"code": [
" gen_inval_exception(ctx, POWERPC_EXCP_PRIV_OPC);",
" gen_inval_exception(ctx, POWERPC_EXCP_PRIV_OPC);",
" if (unlikely(ctx->pr)) {",
" gen_inval_exception(ctx, POWERPC_EXCP_PRIV_OPC);",
" gen_inval_exception(ctx, POWERPC_EXCP_PRIV_OPC);",
" if (unlikely(... | static void FUNC_0(DisasContext *VAR_0)
{
#if defined(CONFIG_USER_ONLY)
gen_inval_exception(VAR_0, POWERPC_EXCP_PRIV_OPC);
#else
TCGv EA, val;
if (unlikely(VAR_0->pr)) {
gen_inval_exception(VAR_0, POWERPC_EXCP_PRIV_OPC);
return;
}
EA = tcg_temp_new();
gen_set_access_ty... | [
"static void FUNC_0(DisasContext *VAR_0)\n{",
"#if defined(CONFIG_USER_ONLY)\ngen_inval_exception(VAR_0, POWERPC_EXCP_PRIV_OPC);",
"#else\nTCGv EA, val;",
"if (unlikely(VAR_0->pr)) {",
"gen_inval_exception(VAR_0, POWERPC_EXCP_PRIV_OPC);",
"return;",
"}",
"EA = tcg_temp_new();",
"gen_set_access_type(... | [
0,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1
] | [
[
1,
3
],
[
5,
7
],
[
9,
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39,
41
]
] |
10,726 | static int setup_common(char *argv[], int argv_sz)
{
memset(cur_ide, 0, sizeof(cur_ide));
return append_arg(0, argv, argv_sz,
g_strdup("-nodefaults -display none"));
}
| true | qemu | 2ad645d2854746b55ddfd1d8e951f689cca5d78f | static int setup_common(char *argv[], int argv_sz)
{
memset(cur_ide, 0, sizeof(cur_ide));
return append_arg(0, argv, argv_sz,
g_strdup("-nodefaults -display none"));
}
| {
"code": [
" g_strdup(\"-nodefaults -display none\"));"
],
"line_no": [
9
]
} | static int FUNC_0(char *VAR_0[], int VAR_1)
{
memset(cur_ide, 0, sizeof(cur_ide));
return append_arg(0, VAR_0, VAR_1,
g_strdup("-nodefaults -display none"));
}
| [
"static int FUNC_0(char *VAR_0[], int VAR_1)\n{",
"memset(cur_ide, 0, sizeof(cur_ide));",
"return append_arg(0, VAR_0, VAR_1,\ng_strdup(\"-nodefaults -display none\"));",
"}"
] | [
0,
0,
1,
0
] | [
[
1,
3
],
[
5
],
[
7,
9
],
[
11
]
] |
10,731 | static int encode_init(AVCodecContext *avctx)
{
HYuvContext *s = avctx->priv_data;
int i, j, width, height;
s->avctx= avctx;
s->flags= avctx->flags;
dsputil_init(&s->dsp, avctx);
width= s->width= avctx->width;
height= s->height= avctx->height;
assert(widt... | true | FFmpeg | 0ecca7a49f8e254c12a3a1de048d738bfbb614c6 | static int encode_init(AVCodecContext *avctx)
{
HYuvContext *s = avctx->priv_data;
int i, j, width, height;
s->avctx= avctx;
s->flags= avctx->flags;
dsputil_init(&s->dsp, avctx);
width= s->width= avctx->width;
height= s->height= avctx->height;
assert(widt... | {
"code": [
" width= s->width= avctx->width;",
" height= s->height= avctx->height;",
" assert(width && height);",
" int i, j, width, height;",
" s->avctx= avctx;",
" s->flags= avctx->flags;",
" dsputil_init(&s->dsp, avctx);",
" width= s->width= avctx->width;",
... | static int FUNC_0(AVCodecContext *VAR_0)
{
HYuvContext *s = VAR_0->priv_data;
int VAR_1, VAR_2, VAR_3, VAR_4;
s->VAR_0= VAR_0;
s->flags= VAR_0->flags;
dsputil_init(&s->dsp, VAR_0);
VAR_3= s->VAR_3= VAR_0->VAR_3;
VAR_4= s->VAR_4= VAR_0->VAR_4;
assert(VAR_3... | [
"static int FUNC_0(AVCodecContext *VAR_0)\n{",
"HYuvContext *s = VAR_0->priv_data;",
"int VAR_1, VAR_2, VAR_3, VAR_4;",
"s->VAR_0= VAR_0;",
"s->flags= VAR_0->flags;",
"dsputil_init(&s->dsp, VAR_0);",
"VAR_3= s->VAR_3= VAR_0->VAR_3;",
"VAR_4= s->VAR_4= VAR_0->VAR_4;",
"assert(VAR_3 && VAR_4);",
"VA... | [
0,
0,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
13
],
[
17
],
[
21
],
[
23
],
[
27
],
[
31
],
[
33
],
[
35
],
[
39
],
[
43
],
[
45,
47
],
[
49
],
[
51,
53
],
[
55
],
[
57... |
10,732 | size_t qemu_file_set_rate_limit(QEMUFile *f, size_t new_rate)
{
if (f->set_rate_limit)
return f->set_rate_limit(f->opaque, new_rate);
return 0;
}
| true | qemu | 0bb05eaff04d30609a98c0dae80bb5dba3e4e799 | size_t qemu_file_set_rate_limit(QEMUFile *f, size_t new_rate)
{
if (f->set_rate_limit)
return f->set_rate_limit(f->opaque, new_rate);
return 0;
}
| {
"code": [
" if (f->set_rate_limit)"
],
"line_no": [
5
]
} | size_t FUNC_0(QEMUFile *f, size_t new_rate)
{
if (f->set_rate_limit)
return f->set_rate_limit(f->opaque, new_rate);
return 0;
}
| [
"size_t FUNC_0(QEMUFile *f, size_t new_rate)\n{",
"if (f->set_rate_limit)\nreturn f->set_rate_limit(f->opaque, new_rate);",
"return 0;",
"}"
] | [
0,
1,
0,
0
] | [
[
1,
3
],
[
5,
7
],
[
11
],
[
13
]
] |
10,733 | static int revert_channel_correlation(ALSDecContext *ctx, ALSBlockData *bd,
ALSChannelData **cd, int *reverted,
unsigned int offset, int c)
{
ALSChannelData *ch = cd[c];
unsigned int dep = 0;
unsigned int channels = ctx->a... | true | FFmpeg | 5c74fa6ce0205c341afb76f6adf2b73c88ff26ef | static int revert_channel_correlation(ALSDecContext *ctx, ALSBlockData *bd,
ALSChannelData **cd, int *reverted,
unsigned int offset, int c)
{
ALSChannelData *ch = cd[c];
unsigned int dep = 0;
unsigned int channels = ctx->a... | {
"code": [
" dep = 0;",
" while (!ch[dep].stop_flag) {",
" dep++;"
],
"line_no": [
73,
75,
35
]
} | static int FUNC_0(ALSDecContext *VAR_0, ALSBlockData *VAR_1,
ALSChannelData **VAR_2, int *VAR_3,
unsigned int VAR_4, int VAR_5)
{
ALSChannelData *ch = VAR_2[VAR_5];
unsigned int VAR_6 = 0;
unsigned int VAR_7 = VAR_0->avctx... | [
"static int FUNC_0(ALSDecContext *VAR_0, ALSBlockData *VAR_1,\nALSChannelData **VAR_2, int *VAR_3,\nunsigned int VAR_4, int VAR_5)\n{",
"ALSChannelData *ch = VAR_2[VAR_5];",
"unsigned int VAR_6 = 0;",
"unsigned int VAR_7 = VAR_0->avctx->VAR_7;",
"if (VAR_3[VAR_5])\nreturn 0;",
"VAR_3[VAR_5] = 1;",
"wh... | [
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,
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
] | [
[
1,
3,
5,
7
],
[
9
],
[
11
],
[
13
],
[
17,
19
],
[
23
],
[
27
],
[
29,
31
],
[
35
],
[
37
],
[
41
],
[
43
],
[
45
],
[
47
],
[
51
],
[
53
],
[
55
],
[
57
... |
10,734 | const char *cpu_parse_cpu_model(const char *typename, const char *cpu_model)
{
ObjectClass *oc;
CPUClass *cc;
Error *err = NULL;
gchar **model_pieces;
const char *cpu_type;
model_pieces = g_strsplit(cpu_model, ",", 2);
oc = cpu_class_by_name(typename, model_pieces[0]);
if (o... | true | qemu | 4482e05cbbb7e50e476f6a9500cf0b38913bd939 | const char *cpu_parse_cpu_model(const char *typename, const char *cpu_model)
{
ObjectClass *oc;
CPUClass *cc;
Error *err = NULL;
gchar **model_pieces;
const char *cpu_type;
model_pieces = g_strsplit(cpu_model, ",", 2);
oc = cpu_class_by_name(typename, model_pieces[0]);
if (o... | {
"code": [
" return NULL;",
" Error *err = NULL;",
" return NULL;",
" cc->parse_features(cpu_type, model_pieces[1], &err);",
" if (err != NULL) {",
" error_report_err(err);",
" return NULL;"
],
"line_no": [
27,
9,
27,
37,
41,
... | const char *FUNC_0(const char *VAR_0, const char *VAR_1)
{
ObjectClass *oc;
CPUClass *cc;
Error *err = NULL;
gchar **model_pieces;
const char *VAR_2;
model_pieces = g_strsplit(VAR_1, ",", 2);
oc = cpu_class_by_name(VAR_0, model_pieces[0]);
if (oc == NULL) {
g_strfre... | [
"const char *FUNC_0(const char *VAR_0, const char *VAR_1)\n{",
"ObjectClass *oc;",
"CPUClass *cc;",
"Error *err = NULL;",
"gchar **model_pieces;",
"const char *VAR_2;",
"model_pieces = g_strsplit(VAR_1, \",\", 2);",
"oc = cpu_class_by_name(VAR_0, model_pieces[0]);",
"if (oc == NULL) {",
"g_strfree... | [
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
1,
0,
1,
1,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
17
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
... |
10,737 | static void find_peaks(DCAEncContext *c)
{
int band, ch;
for (band = 0; band < 32; band++)
for (ch = 0; ch < c->fullband_channels; ch++) {
int sample;
int32_t m = 0;
for (sample = 0; sample < SUBBAND_SAMPLES; sample++) {
int32_t s = abs(c->... | false | FFmpeg | a6191d098a03f94685ae4c072bfdf10afcd86223 | static void find_peaks(DCAEncContext *c)
{
int band, ch;
for (band = 0; band < 32; band++)
for (ch = 0; ch < c->fullband_channels; ch++) {
int sample;
int32_t m = 0;
for (sample = 0; sample < SUBBAND_SAMPLES; sample++) {
int32_t s = abs(c->... | {
"code": [],
"line_no": []
} | static void FUNC_0(DCAEncContext *VAR_0)
{
int VAR_1, VAR_2;
for (VAR_1 = 0; VAR_1 < 32; VAR_1++)
for (VAR_2 = 0; VAR_2 < VAR_0->fullband_channels; VAR_2++) {
int VAR_3;
int32_t m = 0;
for (VAR_3 = 0; VAR_3 < SUBBAND_SAMPLES; VAR_3++) {
int... | [
"static void FUNC_0(DCAEncContext *VAR_0)\n{",
"int VAR_1, VAR_2;",
"for (VAR_1 = 0; VAR_1 < 32; VAR_1++)",
"for (VAR_2 = 0; VAR_2 < VAR_0->fullband_channels; VAR_2++) {",
"int VAR_3;",
"int32_t m = 0;",
"for (VAR_3 = 0; VAR_3 < SUBBAND_SAMPLES; VAR_3++) {",
"int32_t s = abs(VAR_0->subband[VAR_3][VAR_... | [
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
],
[
19
],
[
21
],
[
23,
25
],
[
27
],
[
29
],
[
31
],
[
35
],
[
37
],
[
39
],
[
43
],
[
45,
47
],
[
49
],
[
51... |
10,740 | void av_free(void *ptr)
{
#if CONFIG_MEMALIGN_HACK
if (ptr)
free((char *)ptr - ((char *)ptr)[-1]);
#elif HAVE_ALIGNED_MALLOC
_aligned_free(ptr);
#else
free(ptr);
#endif
}
| true | FFmpeg | 2c21d34ea44d38835f85b90de3cbbf54abb894be | void av_free(void *ptr)
{
#if CONFIG_MEMALIGN_HACK
if (ptr)
free((char *)ptr - ((char *)ptr)[-1]);
#elif HAVE_ALIGNED_MALLOC
_aligned_free(ptr);
#else
free(ptr);
#endif
}
| {
"code": [
" if (ptr)",
" free((char *)ptr - ((char *)ptr)[-1]);"
],
"line_no": [
7,
9
]
} | void FUNC_0(void *VAR_0)
{
#if CONFIG_MEMALIGN_HACK
if (VAR_0)
free((char *)VAR_0 - ((char *)VAR_0)[-1]);
#elif HAVE_ALIGNED_MALLOC
_aligned_free(VAR_0);
#else
free(VAR_0);
#endif
}
| [
"void FUNC_0(void *VAR_0)\n{",
"#if CONFIG_MEMALIGN_HACK\nif (VAR_0)\nfree((char *)VAR_0 - ((char *)VAR_0)[-1]);",
"#elif HAVE_ALIGNED_MALLOC\n_aligned_free(VAR_0);",
"#else\nfree(VAR_0);",
"#endif\n}"
] | [
0,
1,
0,
0,
0
] | [
[
1,
3
],
[
5,
7,
9
],
[
11,
13
],
[
15,
17
],
[
19,
21
]
] |
10,742 | void do_addeo (void)
{
T2 = T0;
T0 += T1 + xer_ca;
if (likely(!(T0 < T2 || (xer_ca == 1 && T0 == T2)))) {
xer_ca = 0;
} else {
xer_ca = 1;
}
if (likely(!((T2 ^ T1 ^ (-1)) & (T2 ^ T0) & (1 << 31)))) {
xer_ov = 0;
} else {
xer_so = 1;
xer_ov... | true | qemu | d9bce9d99f4656ae0b0127f7472db9067b8f84ab | void do_addeo (void)
{
T2 = T0;
T0 += T1 + xer_ca;
if (likely(!(T0 < T2 || (xer_ca == 1 && T0 == T2)))) {
xer_ca = 0;
} else {
xer_ca = 1;
}
if (likely(!((T2 ^ T1 ^ (-1)) & (T2 ^ T0) & (1 << 31)))) {
xer_ov = 0;
} else {
xer_so = 1;
xer_ov... | {
"code": [
" T2 = T0;",
" xer_ca = 1;",
" } else {",
" xer_ca = 0;",
" xer_ca = 1;",
" } else {",
" xer_ca = 0;",
" xer_ca = 1;",
" } else {",
" T2 = T0;",
" if (likely(!((T2 ^ T1 ^ (-1)) & (T2 ^ T0) & (1 << 31)))) {",
... | void FUNC_0 (void)
{
T2 = T0;
T0 += T1 + xer_ca;
if (likely(!(T0 < T2 || (xer_ca == 1 && T0 == T2)))) {
xer_ca = 0;
} else {
xer_ca = 1;
}
if (likely(!((T2 ^ T1 ^ (-1)) & (T2 ^ T0) & (1 << 31)))) {
xer_ov = 0;
} else {
xer_so = 1;
xer_ov =... | [
"void FUNC_0 (void)\n{",
"T2 = T0;",
"T0 += T1 + xer_ca;",
"if (likely(!(T0 < T2 || (xer_ca == 1 && T0 == T2)))) {",
"xer_ca = 0;",
"} else {",
"xer_ca = 1;",
"}",
"if (likely(!((T2 ^ T1 ^ (-1)) & (T2 ^ T0) & (1 << 31)))) {",
"xer_ov = 0;",
"} else {",
"xer_so = 1;",
"xer_ov = 1;",
"}",
... | [
1,
1,
0,
1,
1,
0,
1,
0,
1,
1,
0,
1,
1,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
]
] |
10,743 | static TCGv_i64 gen_mulu_i64_i32(TCGv a, TCGv b)
{
TCGv_i64 tmp1 = tcg_temp_new_i64();
TCGv_i64 tmp2 = tcg_temp_new_i64();
tcg_gen_extu_i32_i64(tmp1, a);
dead_tmp(a);
tcg_gen_extu_i32_i64(tmp2, b);
dead_tmp(b);
tcg_gen_mul_i64(tmp1, tmp1, tmp2);
tcg_temp_free_i64(tmp2);
r... | true | qemu | 7d1b0095bff7157e856d1d0e6c4295641ced2752 | static TCGv_i64 gen_mulu_i64_i32(TCGv a, TCGv b)
{
TCGv_i64 tmp1 = tcg_temp_new_i64();
TCGv_i64 tmp2 = tcg_temp_new_i64();
tcg_gen_extu_i32_i64(tmp1, a);
dead_tmp(a);
tcg_gen_extu_i32_i64(tmp2, b);
dead_tmp(b);
tcg_gen_mul_i64(tmp1, tmp1, tmp2);
tcg_temp_free_i64(tmp2);
r... | {
"code": [
" dead_tmp(b);",
" dead_tmp(b);",
" dead_tmp(a);",
" dead_tmp(b);",
" dead_tmp(a);",
" dead_tmp(b);"
],
"line_no": [
17,
17,
13,
17,
13,
17
]
} | static TCGv_i64 FUNC_0(TCGv a, TCGv b)
{
TCGv_i64 tmp1 = tcg_temp_new_i64();
TCGv_i64 tmp2 = tcg_temp_new_i64();
tcg_gen_extu_i32_i64(tmp1, a);
dead_tmp(a);
tcg_gen_extu_i32_i64(tmp2, b);
dead_tmp(b);
tcg_gen_mul_i64(tmp1, tmp1, tmp2);
tcg_temp_free_i64(tmp2);
return tmp1... | [
"static TCGv_i64 FUNC_0(TCGv a, TCGv b)\n{",
"TCGv_i64 tmp1 = tcg_temp_new_i64();",
"TCGv_i64 tmp2 = tcg_temp_new_i64();",
"tcg_gen_extu_i32_i64(tmp1, a);",
"dead_tmp(a);",
"tcg_gen_extu_i32_i64(tmp2, b);",
"dead_tmp(b);",
"tcg_gen_mul_i64(tmp1, tmp1, tmp2);",
"tcg_temp_free_i64(tmp2);",
"return t... | [
0,
0,
0,
0,
1,
0,
1,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
]
] |
10,745 | static int tta_read_seek(AVFormatContext *s, int stream_index, int64_t timestamp, int flags)
{
TTAContext *c = s->priv_data;
AVStream *st = s->streams[stream_index];
int index = av_index_search_timestamp(st, timestamp, flags);
if (index < 0)
return -1;
c->currentframe = index;
... | true | FFmpeg | e54165aa392322bbeeb823fc33a17336e465b7b5 | static int tta_read_seek(AVFormatContext *s, int stream_index, int64_t timestamp, int flags)
{
TTAContext *c = s->priv_data;
AVStream *st = s->streams[stream_index];
int index = av_index_search_timestamp(st, timestamp, flags);
if (index < 0)
return -1;
c->currentframe = index;
... | {
"code": [
" avio_seek(s->pb, st->index_entries[index].pos, SEEK_SET);"
],
"line_no": [
19
]
} | static int FUNC_0(AVFormatContext *VAR_0, int VAR_1, int64_t VAR_2, int VAR_3)
{
TTAContext *c = VAR_0->priv_data;
AVStream *st = VAR_0->streams[VAR_1];
int VAR_4 = av_index_search_timestamp(st, VAR_2, VAR_3);
if (VAR_4 < 0)
return -1;
c->currentframe = VAR_4;
avio_seek(VAR_0->... | [
"static int FUNC_0(AVFormatContext *VAR_0, int VAR_1, int64_t VAR_2, int VAR_3)\n{",
"TTAContext *c = VAR_0->priv_data;",
"AVStream *st = VAR_0->streams[VAR_1];",
"int VAR_4 = av_index_search_timestamp(st, VAR_2, VAR_3);",
"if (VAR_4 < 0)\nreturn -1;",
"c->currentframe = VAR_4;",
"avio_seek(VAR_0->pb, s... | [
0,
0,
0,
0,
0,
0,
1,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11,
13
],
[
17
],
[
19
],
[
23
],
[
25
]
] |
10,746 | static void quantize_and_encode_band_cost_UQUAD_mips(struct AACEncContext *s,
PutBitContext *pb, const float *in, float *out,
const float *scaled, int size, int scale_idx,
... | true | FFmpeg | 01ecb7172b684f1c4b3e748f95c5a9a494ca36ec | static void quantize_and_encode_band_cost_UQUAD_mips(struct AACEncContext *s,
PutBitContext *pb, const float *in, float *out,
const float *scaled, int size, int scale_idx,
... | {
"code": [
" int *bits, const float ROUNDING)",
" if (out) {",
" vec = &p_vec[curidx*4];",
" int *bits, const float ROUNDING)",
" if (out) {",
" vec = &p_v... | static void FUNC_0(struct AACEncContext *VAR_0,
PutBitContext *VAR_1, const float *VAR_2, float *VAR_3,
const float *VAR_4, int VAR_5, int VAR_6,
int VAR_7, c... | [
"static void FUNC_0(struct AACEncContext *VAR_0,\nPutBitContext *VAR_1, const float *VAR_2, float *VAR_3,\nconst float *VAR_4, int VAR_5, int VAR_6,\nint VAR_7, const float VAR_8, const float VAR_9,\nint *VAR_10, const float VAR_11)\n{",
"const float VAR_12 = ff_aac_pow34sf_tab[POW_SF2_ZERO - VAR_6 + SCALE_ONE_PO... | [
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
1,
1,
1,
1,
1,
0,
0,
0
] | [
[
1,
3,
5,
7,
9,
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
23
],
[
25
],
[
27
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[
51
... |
10,747 | void ff_aac_update_ltp(AACEncContext *s, SingleChannelElement *sce)
{
int i, j, lag;
float corr, s0, s1, max_corr = 0.0f;
float *samples = &s->planar_samples[s->cur_channel][1024];
float *pred_signal = &sce->ltp_state[0];
int samples_num = 2048;
if (s->profile != FF_PROFILE_AAC_LTP)
... | true | FFmpeg | 780dba01f9aed8c9b6ba05eceac2fe3eac71198b | void ff_aac_update_ltp(AACEncContext *s, SingleChannelElement *sce)
{
int i, j, lag;
float corr, s0, s1, max_corr = 0.0f;
float *samples = &s->planar_samples[s->cur_channel][1024];
float *pred_signal = &sce->ltp_state[0];
int samples_num = 2048;
if (s->profile != FF_PROFILE_AAC_LTP)
... | {
"code": [],
"line_no": []
} | void FUNC_0(AACEncContext *VAR_0, SingleChannelElement *VAR_1)
{
int VAR_2, VAR_3, VAR_4;
float VAR_5, VAR_6, VAR_7, VAR_8 = 0.0f;
float *VAR_9 = &VAR_0->planar_samples[VAR_0->cur_channel][1024];
float *VAR_10 = &VAR_1->ltp_state[0];
int VAR_11 = 2048;
if (VAR_0->profile != FF_PROFILE_A... | [
"void FUNC_0(AACEncContext *VAR_0, SingleChannelElement *VAR_1)\n{",
"int VAR_2, VAR_3, VAR_4;",
"float VAR_5, VAR_6, VAR_7, VAR_8 = 0.0f;",
"float *VAR_9 = &VAR_0->planar_samples[VAR_0->cur_channel][1024];",
"float *VAR_10 = &VAR_1->ltp_state[0];",
"int VAR_11 = 2048;",
"if (VAR_0->profile != FF_PROFIL... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
25
],
[
27
],
[
29
],
[
31,
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49
... |
10,748 | static void z2_init(MachineState *machine)
{
const char *cpu_model = machine->cpu_model;
const char *kernel_filename = machine->kernel_filename;
const char *kernel_cmdline = machine->kernel_cmdline;
const char *initrd_filename = machine->initrd_filename;
MemoryRegion *address_space_mem = get_s... | true | qemu | f3c7d0389fe8a2792fd4c1cf151b885de03c8f62 | static void z2_init(MachineState *machine)
{
const char *cpu_model = machine->cpu_model;
const char *kernel_filename = machine->kernel_filename;
const char *kernel_cmdline = machine->kernel_cmdline;
const char *initrd_filename = machine->initrd_filename;
MemoryRegion *address_space_mem = get_s... | {
"code": [
" qemu_allocate_irqs(z2_lcd_cs, z2_lcd, 1)[0]);"
],
"line_no": [
127
]
} | static void FUNC_0(MachineState *VAR_0)
{
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;
MemoryRegion *address_space_mem = get_system_memory();
uint32_t sector_len = 0x10000;
PXA2xxState *mpu;
... | [
"static void FUNC_0(MachineState *VAR_0)\n{",
"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;",
"MemoryRegion *address_space_mem = get_system_memory();",
"uint32_t sector_len = 0x10000;",
"PXA2xxState *mp... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
31
],
[
33
],
[
35
],
[
41
],
[
45,
47
],
[
49,
51
... |
10,749 | void ff_put_h264_qpel16_mc20_msa(uint8_t *dst, const uint8_t *src,
ptrdiff_t stride)
{
avc_luma_hz_16w_msa(src - 2, stride, dst, stride, 16);
}
| false | FFmpeg | 6796a1dd8c14843b77925cb83a3ef88706ae1dd0 | void ff_put_h264_qpel16_mc20_msa(uint8_t *dst, const uint8_t *src,
ptrdiff_t stride)
{
avc_luma_hz_16w_msa(src - 2, stride, dst, stride, 16);
}
| {
"code": [],
"line_no": []
} | void FUNC_0(uint8_t *VAR_0, const uint8_t *VAR_1,
ptrdiff_t VAR_2)
{
avc_luma_hz_16w_msa(VAR_1 - 2, VAR_2, VAR_0, VAR_2, 16);
}
| [
"void FUNC_0(uint8_t *VAR_0, const uint8_t *VAR_1,\nptrdiff_t VAR_2)\n{",
"avc_luma_hz_16w_msa(VAR_1 - 2, VAR_2, VAR_0, VAR_2, 16);",
"}"
] | [
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
]
] |
10,752 | void avformat_free_context(AVFormatContext *s)
{
int i;
AVStream *st;
av_opt_free(s);
if (s->iformat && s->iformat->priv_class && s->priv_data)
av_opt_free(s->priv_data);
for(i=0;i<s->nb_streams;i++) {
/* free all data in a stream component */
st = s->streams[i];... | false | FFmpeg | 27c7ca9c12bb42d5c44d46f24cd970469d0ef55a | void avformat_free_context(AVFormatContext *s)
{
int i;
AVStream *st;
av_opt_free(s);
if (s->iformat && s->iformat->priv_class && s->priv_data)
av_opt_free(s->priv_data);
for(i=0;i<s->nb_streams;i++) {
st = s->streams[i];
if (st->parser) {
... | {
"code": [],
"line_no": []
} | void FUNC_0(AVFormatContext *VAR_0)
{
int VAR_1;
AVStream *st;
av_opt_free(VAR_0);
if (VAR_0->iformat && VAR_0->iformat->priv_class && VAR_0->priv_data)
av_opt_free(VAR_0->priv_data);
for(VAR_1=0;VAR_1<VAR_0->nb_streams;VAR_1++) {
st = VAR_0->streams[VAR_1];
... | [
"void FUNC_0(AVFormatContext *VAR_0)\n{",
"int VAR_1;",
"AVStream *st;",
"av_opt_free(VAR_0);",
"if (VAR_0->iformat && VAR_0->iformat->priv_class && VAR_0->priv_data)\nav_opt_free(VAR_0->priv_data);",
"for(VAR_1=0;VAR_1<VAR_0->nb_streams;VAR_1++) {",
"st = VAR_0->streams[VAR_1];",
"if (st->parser) {",... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
13,
15
],
[
19
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33,
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49... |
10,753 | static int encode_rgb_frame(FFV1Context *s, uint8_t *src[3], int w, int h, int stride[3])
{
int x, y, p, i;
const int ring_size = s->avctx->context_model ? 3 : 2;
int16_t *sample[4][3];
int lbd = s->bits_per_raw_sample <= 8;
int bits = s->bits_per_raw_sample > 0 ? s->bits_per_raw_sample :... | false | FFmpeg | 3576b564ec4ffa98402b02b3a69171cefd103eb0 | static int encode_rgb_frame(FFV1Context *s, uint8_t *src[3], int w, int h, int stride[3])
{
int x, y, p, i;
const int ring_size = s->avctx->context_model ? 3 : 2;
int16_t *sample[4][3];
int lbd = s->bits_per_raw_sample <= 8;
int bits = s->bits_per_raw_sample > 0 ? s->bits_per_raw_sample :... | {
"code": [],
"line_no": []
} | static int FUNC_0(FFV1Context *VAR_0, uint8_t *VAR_1[3], int VAR_2, int VAR_3, int VAR_4[3])
{
int VAR_5, VAR_6, VAR_7, VAR_8;
const int VAR_9 = VAR_0->avctx->context_model ? 3 : 2;
int16_t *sample[4][3];
int VAR_10 = VAR_0->bits_per_raw_sample <= 8;
int VAR_11 = VAR_0->bits_per_raw_sampl... | [
"static int FUNC_0(FFV1Context *VAR_0, uint8_t *VAR_1[3], int VAR_2, int VAR_3, int VAR_4[3])\n{",
"int VAR_5, VAR_6, VAR_7, VAR_8;",
"const int VAR_9 = VAR_0->avctx->context_model ? 3 : 2;",
"int16_t *sample[4][3];",
"int VAR_10 = VAR_0->bits_per_raw_sample <= 8;",
"int VAR_11 = VAR_0->bits_per_raw_... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
23,
25
],
[
29
],
[
31
],
[
33
],
[
35
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49
],
[... |
10,754 | av_cold int sws_init_context(SwsContext *c, SwsFilter *srcFilter,
SwsFilter *dstFilter)
{
int i;
int usesVFilter, usesHFilter;
int unscaled;
SwsFilter dummyFilter = { NULL, NULL, NULL, NULL };
int srcW = c->srcW;
int srcH = c->srcH;
... | false | FFmpeg | e0c6cce44729d94e2a5507a4b6d031f23e8bd7b6 | av_cold int sws_init_context(SwsContext *c, SwsFilter *srcFilter,
SwsFilter *dstFilter)
{
int i;
int usesVFilter, usesHFilter;
int unscaled;
SwsFilter dummyFilter = { NULL, NULL, NULL, NULL };
int srcW = c->srcW;
int srcH = c->srcH;
... | {
"code": [],
"line_no": []
} | av_cold int FUNC_0(SwsContext *c, SwsFilter *srcFilter,
SwsFilter *dstFilter)
{
int VAR_0;
int VAR_1, VAR_2;
int VAR_3;
SwsFilter dummyFilter = { NULL, NULL, NULL, NULL };
int VAR_4 = c->VAR_4;
int VAR_5 = c->VAR_5;
int VAR_6 ... | [
"av_cold int FUNC_0(SwsContext *c, SwsFilter *srcFilter,\nSwsFilter *dstFilter)\n{",
"int VAR_0;",
"int VAR_1, VAR_2;",
"int VAR_3;",
"SwsFilter dummyFilter = { NULL, NULL, NULL, NULL };",
"int VAR_4 = c->VAR_4;",
"int VAR_5 = c->VAR_5;",
"int VAR_6 = c->VAR_6;",... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
35
],
[
37
],
[
39
],
[
41,
43
],
[
47
... |
10,755 | static int vsink_query_formats(AVFilterContext *ctx)
{
BufferSinkContext *buf = ctx->priv;
AVFilterFormats *formats = NULL;
unsigned i;
int ret;
if (buf->pixel_fmts_size % sizeof(*buf->pixel_fmts)) {
av_log(ctx, AV_LOG_ERROR, "Invalid size for format list\n");
return AVERRO... | false | FFmpeg | 6fbb21d6858b9d0152f89e1b30ffe683a9d33948 | static int vsink_query_formats(AVFilterContext *ctx)
{
BufferSinkContext *buf = ctx->priv;
AVFilterFormats *formats = NULL;
unsigned i;
int ret;
if (buf->pixel_fmts_size % sizeof(*buf->pixel_fmts)) {
av_log(ctx, AV_LOG_ERROR, "Invalid size for format list\n");
return AVERRO... | {
"code": [],
"line_no": []
} | static int FUNC_0(AVFilterContext *VAR_0)
{
BufferSinkContext *buf = VAR_0->priv;
AVFilterFormats *formats = NULL;
unsigned VAR_1;
int VAR_2;
if (buf->pixel_fmts_size % sizeof(*buf->pixel_fmts)) {
av_log(VAR_0, AV_LOG_ERROR, "Invalid size for format list\n");
return AVERROR... | [
"static int FUNC_0(AVFilterContext *VAR_0)\n{",
"BufferSinkContext *buf = VAR_0->priv;",
"AVFilterFormats *formats = NULL;",
"unsigned VAR_1;",
"int VAR_2;",
"if (buf->pixel_fmts_size % sizeof(*buf->pixel_fmts)) {",
"av_log(VAR_0, AV_LOG_ERROR, \"Invalid size for format list\\n\");",
"return AVERROR(E... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
15
],
[
17
],
[
19
],
[
21
],
[
25
],
[
27
],
[
29,
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
43
],
[
45
]
] |
10,756 | av_cold void ff_vp56_init(AVCodecContext *avctx, int flip, int has_alpha)
{
VP56Context *s = avctx->priv_data;
int i;
s->avctx = avctx;
avctx->pix_fmt = has_alpha ? PIX_FMT_YUVA420P : PIX_FMT_YUV420P;
if (avctx->idct_algo == FF_IDCT_AUTO)
avctx->idct_algo = FF_IDCT_VP3;
ff_ds... | false | FFmpeg | 28f9ab7029bd1a02f659995919f899f84ee7361b | av_cold void ff_vp56_init(AVCodecContext *avctx, int flip, int has_alpha)
{
VP56Context *s = avctx->priv_data;
int i;
s->avctx = avctx;
avctx->pix_fmt = has_alpha ? PIX_FMT_YUVA420P : PIX_FMT_YUV420P;
if (avctx->idct_algo == FF_IDCT_AUTO)
avctx->idct_algo = FF_IDCT_VP3;
ff_ds... | {
"code": [],
"line_no": []
} | av_cold void FUNC_0(AVCodecContext *avctx, int flip, int has_alpha)
{
VP56Context *s = avctx->priv_data;
int VAR_0;
s->avctx = avctx;
avctx->pix_fmt = has_alpha ? PIX_FMT_YUVA420P : PIX_FMT_YUV420P;
if (avctx->idct_algo == FF_IDCT_AUTO)
avctx->idct_algo = FF_IDCT_VP3;
ff_dspu... | [
"av_cold void FUNC_0(AVCodecContext *avctx, int flip, int has_alpha)\n{",
"VP56Context *s = avctx->priv_data;",
"int VAR_0;",
"s->avctx = avctx;",
"avctx->pix_fmt = has_alpha ? PIX_FMT_YUVA420P : PIX_FMT_YUV420P;",
"if (avctx->idct_algo == FF_IDCT_AUTO)\navctx->idct_algo = FF_IDCT_VP3;",
"ff_dsputil_ini... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
13
],
[
17,
19
],
[
21
],
[
23
],
[
25
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
41
],
[
43
],
[
45
],
[
47
],
[
51
],
... |
10,757 | static int sd_snapshot_delete(BlockDriverState *bs, const char *snapshot_id)
{
/* FIXME: Delete specified snapshot id. */
return 0;
}
| true | qemu | a89d89d3e65800fa4a8e00de7af0ea8272bef779 | static int sd_snapshot_delete(BlockDriverState *bs, const char *snapshot_id)
{
return 0;
}
| {
"code": [
"static int sd_snapshot_delete(BlockDriverState *bs, const char *snapshot_id)"
],
"line_no": [
1
]
} | static int FUNC_0(BlockDriverState *VAR_0, const char *VAR_1)
{
return 0;
}
| [
"static int FUNC_0(BlockDriverState *VAR_0, const char *VAR_1)\n{",
"return 0;",
"}"
] | [
1,
0,
0
] | [
[
1,
3
],
[
7
],
[
9
]
] |
10,758 | static int rso_read_packet(AVFormatContext *s, AVPacket *pkt)
{
int bps = av_get_bits_per_sample(s->streams[0]->codec->codec_id);
int ret = av_get_packet(s->pb, pkt, BLOCK_SIZE * bps >> 3);
if (ret < 0)
return ret;
pkt->stream_index = 0;
/* note: we need to modify the packet si... | true | FFmpeg | 7effbee66cf457c62f795d9b9ed3a1110b364b89 | static int rso_read_packet(AVFormatContext *s, AVPacket *pkt)
{
int bps = av_get_bits_per_sample(s->streams[0]->codec->codec_id);
int ret = av_get_packet(s->pb, pkt, BLOCK_SIZE * bps >> 3);
if (ret < 0)
return ret;
pkt->stream_index = 0;
pkt->size = ret;
return 0;
... | {
"code": [],
"line_no": []
} | static int FUNC_0(AVFormatContext *VAR_0, AVPacket *VAR_1)
{
int VAR_2 = av_get_bits_per_sample(VAR_0->streams[0]->codec->codec_id);
int VAR_3 = av_get_packet(VAR_0->pb, VAR_1, BLOCK_SIZE * VAR_2 >> 3);
if (VAR_3 < 0)
return VAR_3;
VAR_1->stream_index = 0;
VAR_1->size = V... | [
"static int FUNC_0(AVFormatContext *VAR_0, AVPacket *VAR_1)\n{",
"int VAR_2 = av_get_bits_per_sample(VAR_0->streams[0]->codec->codec_id);",
"int VAR_3 = av_get_packet(VAR_0->pb, VAR_1, BLOCK_SIZE * VAR_2 >> 3);",
"if (VAR_3 < 0)\nreturn VAR_3;",
"VAR_1->stream_index = 0;",
"VAR_1->size = VAR_3;",
"retur... | [
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11,
13
],
[
18
],
[
24
],
[
28
],
[
30
]
] |
10,759 | static int vmd_read_header(AVFormatContext *s)
{
VmdDemuxContext *vmd = s->priv_data;
AVIOContext *pb = s->pb;
AVStream *st = NULL, *vst;
unsigned int toc_offset;
unsigned char *raw_frame_table;
int raw_frame_table_size;
int64_t current_offset;
int i, j;
unsigned int total_... | true | FFmpeg | 0ef1660a6365ce60ead8858936b6f3f8ea862826 | static int vmd_read_header(AVFormatContext *s)
{
VmdDemuxContext *vmd = s->priv_data;
AVIOContext *pb = s->pb;
AVStream *st = NULL, *vst;
unsigned int toc_offset;
unsigned char *raw_frame_table;
int raw_frame_table_size;
int64_t current_offset;
int i, j;
unsigned int total_... | {
"code": [
" int i, j;",
" av_free(raw_frame_table);",
" av_free(vmd->frame_table);",
" return AVERROR(ENOMEM);",
" av_free(raw_frame_table);",
" av_free(vmd->frame_table);",
" return AVERROR(EIO);"
],
"line_no": [
19,
193,
195,... | static int FUNC_0(AVFormatContext *VAR_0)
{
VmdDemuxContext *vmd = VAR_0->priv_data;
AVIOContext *pb = VAR_0->pb;
AVStream *st = NULL, *vst;
unsigned int VAR_1;
unsigned char *VAR_2;
int VAR_3;
int64_t current_offset;
int VAR_4, VAR_5;
unsigned int VAR_6;
int64_t curre... | [
"static int FUNC_0(AVFormatContext *VAR_0)\n{",
"VmdDemuxContext *vmd = VAR_0->priv_data;",
"AVIOContext *pb = VAR_0->pb;",
"AVStream *st = NULL, *vst;",
"unsigned int VAR_1;",
"unsigned char *VAR_2;",
"int VAR_3;",
"int64_t current_offset;",
"int VAR_4, VAR_5;",
"unsigned int VAR_6;",
"int64_t ... | [
0,
0,
0,
0,
0,
0,
0,
0,
1,
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,
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
],
[
35
],
[
37,
39
],
[
43,
45
],
[
47,
49
],
[... |
10,760 | static int read_f(BlockBackend *blk, int argc, char **argv)
{
struct timeval t1, t2;
bool Cflag = false, qflag = false, vflag = false;
bool Pflag = false, sflag = false, lflag = false, bflag = false;
int c, cnt;
char *buf;
int64_t offset;
int64_t count;
/* Some compilers get con... | true | qemu | 3026c4688ca80d9c5cc1606368c4a1009a6f507d | static int read_f(BlockBackend *blk, int argc, char **argv)
{
struct timeval t1, t2;
bool Cflag = false, qflag = false, vflag = false;
bool Pflag = false, sflag = false, lflag = false, bflag = false;
int c, cnt;
char *buf;
int64_t offset;
int64_t count;
int64_t total = 0;
... | {
"code": [
" } else if (count > SIZE_MAX) {",
" (uint64_t) SIZE_MAX, argv[optind]);",
" } else if (count > SIZE_MAX) {",
" (uint64_t) SIZE_MAX, argv[optind]);"
],
"line_no": [
149,
153,
149,
153
]
} | static int FUNC_0(BlockBackend *VAR_0, int VAR_1, char **VAR_2)
{
struct timeval VAR_3, VAR_4;
bool Cflag = false, qflag = false, vflag = false;
bool Pflag = false, sflag = false, lflag = false, bflag = false;
int VAR_5, VAR_6;
char *VAR_7;
int64_t offset;
int64_t count;
i... | [
"static int FUNC_0(BlockBackend *VAR_0, int VAR_1, char **VAR_2)\n{",
"struct timeval VAR_3, VAR_4;",
"bool Cflag = false, qflag = false, vflag = false;",
"bool Pflag = false, sflag = false, lflag = false, bflag = false;",
"int VAR_5, VAR_6;",
"char *VAR_7;",
"int64_t offset;",
"int64_t count;",
"in... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
1,
0,
0,
0,
0... | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
21
],
[
23
],
[
25
],
[
29
],
[
31
],
[
33,
35
],
[
37
],
[
39,
41
],
[
43
],
[
45,
47
],
[... |
10,761 | PPC_OP(subfze)
{
T1 = ~T0;
T0 = T1 + xer_ca;
if (T0 < T1) {
xer_ca = 1;
} else {
xer_ca = 0;
}
RETURN();
}
| true | qemu | d9bce9d99f4656ae0b0127f7472db9067b8f84ab | PPC_OP(subfze)
{
T1 = ~T0;
T0 = T1 + xer_ca;
if (T0 < T1) {
xer_ca = 1;
} else {
xer_ca = 0;
}
RETURN();
}
| {
"code": [
" RETURN();",
" xer_ca = 1;",
" if (T0 < T1) {",
" } else {",
" xer_ca = 0;",
" if (T0 < T1) {",
" xer_ca = 1;",
" } else {",
" xer_ca = 0;",
" xer_ca = 1;",
" } else {",
"PPC_OP(subfze)",
" if (T0 ... | FUNC_0(VAR_0)
{
T1 = ~T0;
T0 = T1 + xer_ca;
if (T0 < T1) {
xer_ca = 1;
} else {
xer_ca = 0;
}
RETURN();
}
| [
"FUNC_0(VAR_0)\n{",
"T1 = ~T0;",
"T0 = T1 + xer_ca;",
"if (T0 < T1) {",
"xer_ca = 1;",
"} else {",
"xer_ca = 0;",
"}",
"RETURN();",
"}"
] | [
1,
0,
0,
1,
1,
0,
1,
0,
1,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
]
] |
10,763 | void ff_celp_lp_zero_synthesis_filterf(float *out,
const float* filter_coeffs,
const float* in,
int buffer_length,
int filter_length)
{
int i,n;
//... | false | FFmpeg | b1ade3d1821a29174963b28cd0caa5f7ed394998 | void ff_celp_lp_zero_synthesis_filterf(float *out,
const float* filter_coeffs,
const float* in,
int buffer_length,
int filter_length)
{
int i,n;
... | {
"code": [],
"line_no": []
} | void FUNC_0(float *VAR_0,
const float* VAR_1,
const float* VAR_2,
int VAR_3,
int VAR_4)
{
int VAR_5,VAR_6;
VAR_4++;
for (VAR_6 = 0; VA... | [
"void FUNC_0(float *VAR_0,\nconst float* VAR_1,\nconst float* VAR_2,\nint VAR_3,\nint VAR_4)\n{",
"int VAR_5,VAR_6;",
"VAR_4++;",
"for (VAR_6 = 0; VAR_6 < VAR_3; VAR_6++) {",
"VAR_0[VAR_6] = VAR_2[VAR_6];",
"for (VAR_5 = 1; VAR_5 < VAR_4; VAR_5++)",
"VAR_0[VAR_6] += VAR_1[VAR_5-1] * VAR_2[VAR_6-VAR_5];"... | [
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5,
7,
9,
11
],
[
13
],
[
19
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
]
] |
10,764 | static int RENAME(epzs_motion_search2)(MpegEncContext * s,
int *mx_ptr, int *my_ptr,
int P[10][2], int pred_x, int pred_y,
uint8_t *src_data[3],
uint8_t *ref_data[3], int stride, int uvstride, int16_... | false | FFmpeg | 80ee9fc0e305b815b4b67bbf8fa9ceccdc1d369e | static int RENAME(epzs_motion_search2)(MpegEncContext * s,
int *mx_ptr, int *my_ptr,
int P[10][2], int pred_x, int pred_y,
uint8_t *src_data[3],
uint8_t *ref_data[3], int stride, int uvstride, int16_... | {
"code": [],
"line_no": []
} | static int FUNC_0(epzs_motion_search2)(MpegEncContext * s,
int *mx_ptr, int *my_ptr,
int P[10][2], int pred_x, int pred_y,
uint8_t *src_data[3],
uint8_t *ref_data[3], int stride, int uvstride, int16_... | [
"static int FUNC_0(epzs_motion_search2)(MpegEncContext * s,\nint *mx_ptr, int *my_ptr,\nint P[10][2], int pred_x, int pred_y,\nuint8_t *src_data[3],\nuint8_t *ref_data[3], int stride, int uvstride, int16_t (*last_mv)[2],\nint ref_mv_scale, uint8_t * const mv_penalty)\n{",
"int VAR_0[2]={0, 0};",
"int 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
] | [
[
1,
3,
5,
7,
9,
11,
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37,
41
],
[
43
],
[
47
],
[
51
],
[
57
... |
10,766 | static int decode_p_block(FourXContext *f, uint16_t *dst, uint16_t *src,
int log2w, int log2h, int stride)
{
const int index = size2index[log2h][log2w];
const int h = 1 << log2h;
int code = get_vlc2(&f->gb,
block_type_vlc[1 - (f->vers... | false | FFmpeg | 68a35473ed423a14731c418939fba7913647979a | static int decode_p_block(FourXContext *f, uint16_t *dst, uint16_t *src,
int log2w, int log2h, int stride)
{
const int index = size2index[log2h][log2w];
const int h = 1 << log2h;
int code = get_vlc2(&f->gb,
block_type_vlc[1 - (f->vers... | {
"code": [],
"line_no": []
} | static int FUNC_0(FourXContext *VAR_0, uint16_t *VAR_1, uint16_t *VAR_2,
int VAR_3, int VAR_4, int VAR_5)
{
const int VAR_6 = size2index[VAR_4][VAR_3];
const int VAR_7 = 1 << VAR_4;
int VAR_8 = get_vlc2(&VAR_0->gb,
block_type_vlc[1 - ... | [
"static int FUNC_0(FourXContext *VAR_0, uint16_t *VAR_1, uint16_t *VAR_2,\nint VAR_3, int VAR_4, int VAR_5)\n{",
"const int VAR_6 = size2index[VAR_4][VAR_3];",
"const int VAR_7 = 1 << VAR_4;",
"int VAR_8 = get_vlc2(&VAR_0->gb,\nblock_type_vlc[1 - (VAR_0->version > 1)][VAR_6].table,\nBLOCK_TYPE_VLC_... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11,
13,
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
29,
31
],
[
35
],
[
37
],
[
39,
41
],
[
43,
45,
47
],
[
49
],
[
51
],
[... |
10,768 | static void achroma(WaveformContext *s, AVFrame *in, AVFrame *out,
int component, int intensity, int offset, int column)
{
const int plane = s->desc->comp[component].plane;
const int mirror = s->mirror;
const int c1_linesize = in->linesize[(plane + 1) % s->ncomp];
const int c2_... | false | FFmpeg | 5b349c8d7cc5dd26b3fbbce6e3883ce02861eeb7 | static void achroma(WaveformContext *s, AVFrame *in, AVFrame *out,
int component, int intensity, int offset, int column)
{
const int plane = s->desc->comp[component].plane;
const int mirror = s->mirror;
const int c1_linesize = in->linesize[(plane + 1) % s->ncomp];
const int c2_... | {
"code": [],
"line_no": []
} | static void FUNC_0(WaveformContext *VAR_0, AVFrame *VAR_1, AVFrame *VAR_2,
int VAR_3, int VAR_4, int VAR_5, int VAR_6)
{
const int VAR_7 = VAR_0->desc->comp[VAR_3].VAR_7;
const int VAR_8 = VAR_0->VAR_8;
const int VAR_9 = VAR_1->linesize[(VAR_7 + 1) % VAR_0->ncomp];
const int VA... | [
"static void FUNC_0(WaveformContext *VAR_0, AVFrame *VAR_1, AVFrame *VAR_2,\nint VAR_3, int VAR_4, int VAR_5, int VAR_6)\n{",
"const int VAR_7 = VAR_0->desc->comp[VAR_3].VAR_7;",
"const int VAR_8 = VAR_0->VAR_8;",
"const int VAR_9 = VAR_1->linesize[(VAR_7 + 1) % VAR_0->ncomp];",
"const int VAR_10 = VAR_1->l... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
29
],
[
31
],
[
33
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[... |
10,769 | static int flac_probe(AVProbeData *p)
{
uint8_t *bufptr = p->buf;
if(ff_id3v2_match(bufptr))
bufptr += ff_id3v2_tag_len(bufptr);
if(memcmp(bufptr, "fLaC", 4)) return 0;
else return AVPROBE_SCORE_MAX / 2;
}
| false | FFmpeg | 16f753f43fba3b9b16cb9fa62e99f481aaa29ae9 | static int flac_probe(AVProbeData *p)
{
uint8_t *bufptr = p->buf;
if(ff_id3v2_match(bufptr))
bufptr += ff_id3v2_tag_len(bufptr);
if(memcmp(bufptr, "fLaC", 4)) return 0;
else return AVPROBE_SCORE_MAX / 2;
}
| {
"code": [],
"line_no": []
} | static int FUNC_0(AVProbeData *VAR_0)
{
uint8_t *bufptr = VAR_0->buf;
if(ff_id3v2_match(bufptr))
bufptr += ff_id3v2_tag_len(bufptr);
if(memcmp(bufptr, "fLaC", 4)) return 0;
else return AVPROBE_SCORE_MAX / 2;
}
| [
"static int FUNC_0(AVProbeData *VAR_0)\n{",
"uint8_t *bufptr = VAR_0->buf;",
"if(ff_id3v2_match(bufptr))\nbufptr += ff_id3v2_tag_len(bufptr);",
"if(memcmp(bufptr, \"fLaC\", 4)) return 0;",
"else return AVPROBE_SCORE_MAX / 2;",
"}"
] | [
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9,
11
],
[
15
],
[
17
],
[
19
]
] |
10,770 | static av_always_inline void decode_dc_coeffs(GetBitContext *gb, DCTELEM *out,
int blocks_per_slice)
{
DCTELEM prev_dc;
int code, i, sign;
OPEN_READER(re, gb);
DECODE_CODEWORD(code, FIRST_DC_CB);
prev_dc = TOSIGNED(code);
out[0] = prev_dc... | false | FFmpeg | 006508032057824a371bec4e629b66f8cbb26c47 | static av_always_inline void decode_dc_coeffs(GetBitContext *gb, DCTELEM *out,
int blocks_per_slice)
{
DCTELEM prev_dc;
int code, i, sign;
OPEN_READER(re, gb);
DECODE_CODEWORD(code, FIRST_DC_CB);
prev_dc = TOSIGNED(code);
out[0] = prev_dc... | {
"code": [],
"line_no": []
} | static av_always_inline void FUNC_0(GetBitContext *gb, DCTELEM *out,
int blocks_per_slice)
{
DCTELEM prev_dc;
int VAR_0, VAR_1, VAR_2;
OPEN_READER(re, gb);
DECODE_CODEWORD(VAR_0, FIRST_DC_CB);
prev_dc = TOSIGNED(VAR_0);
out[0] = prev_dc;
... | [
"static av_always_inline void FUNC_0(GetBitContext *gb, DCTELEM *out,\nint blocks_per_slice)\n{",
"DCTELEM prev_dc;",
"int VAR_0, VAR_1, VAR_2;",
"OPEN_READER(re, gb);",
"DECODE_CODEWORD(VAR_0, FIRST_DC_CB);",
"prev_dc = TOSIGNED(VAR_0);",
"out[0] = prev_dc;",
"out += 64;",
"VAR_0 = 5;",
"VAR_2 = ... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
13
],
[
17
],
[
19
],
[
21
],
[
25
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49
]
] |
10,771 | int av_vdpau_bind_context(AVCodecContext *avctx, VdpDevice device,
VdpGetProcAddress *get_proc, unsigned flags)
{
VDPAUHWContext *hwctx;
if (flags != 0)
return AVERROR(EINVAL);
if (av_reallocp(&avctx->hwaccel_context, sizeof(*hwctx)))
return AVERROR(ENOME... | true | FFmpeg | d565fef1b83b6c5f8afb32229260b79f67c68109 | int av_vdpau_bind_context(AVCodecContext *avctx, VdpDevice device,
VdpGetProcAddress *get_proc, unsigned flags)
{
VDPAUHWContext *hwctx;
if (flags != 0)
return AVERROR(EINVAL);
if (av_reallocp(&avctx->hwaccel_context, sizeof(*hwctx)))
return AVERROR(ENOME... | {
"code": [
" if (flags != 0)"
],
"line_no": [
11
]
} | int FUNC_0(AVCodecContext *VAR_0, VdpDevice VAR_1,
VdpGetProcAddress *VAR_2, unsigned VAR_3)
{
VDPAUHWContext *hwctx;
if (VAR_3 != 0)
return AVERROR(EINVAL);
if (av_reallocp(&VAR_0->hwaccel_context, sizeof(*hwctx)))
return AVERROR(ENOMEM);
hwctx = ... | [
"int FUNC_0(AVCodecContext *VAR_0, VdpDevice VAR_1,\nVdpGetProcAddress *VAR_2, unsigned VAR_3)\n{",
"VDPAUHWContext *hwctx;",
"if (VAR_3 != 0)\nreturn AVERROR(EINVAL);",
"if (av_reallocp(&VAR_0->hwaccel_context, sizeof(*hwctx)))\nreturn AVERROR(ENOMEM);",
"hwctx = VAR_0->hwaccel_context;",
"memset(hwctx, ... | [
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
11,
13
],
[
17,
19
],
[
23
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
]
] |
10,774 | static int decode_ref_pic_marking(H264Context *h){
MpegEncContext * const s = &h->s;
int i;
if(h->nal_unit_type == NAL_IDR_SLICE){ //FIXME fields
s->broken_link= get_bits1(&s->gb) -1;
h->mmco[0].long_index= get_bits1(&s->gb) - 1; // current_long_term_idx
if(h->mmco[0].long_in... | true | FFmpeg | 88e7a4d18c63799a21dff4a570ceb8008e310820 | static int decode_ref_pic_marking(H264Context *h){
MpegEncContext * const s = &h->s;
int i;
if(h->nal_unit_type == NAL_IDR_SLICE){
s->broken_link= get_bits1(&s->gb) -1;
h->mmco[0].long_index= get_bits1(&s->gb) - 1;
if(h->mmco[0].long_index == -1)
h->mmco_index=... | {
"code": [
" h->mmco[i].long_index= get_ue_golomb(&s->gb);",
" if(opcode > MMCO_LONG){"
],
"line_no": [
55,
69
]
} | static int FUNC_0(H264Context *VAR_0){
MpegEncContext * const s = &VAR_0->s;
int VAR_1;
if(VAR_0->nal_unit_type == NAL_IDR_SLICE){
s->broken_link= get_bits1(&s->gb) -1;
VAR_0->mmco[0].long_index= get_bits1(&s->gb) - 1;
if(VAR_0->mmco[0].long_index == -1)
VAR_0-... | [
"static int FUNC_0(H264Context *VAR_0){",
"MpegEncContext * const s = &VAR_0->s;",
"int VAR_1;",
"if(VAR_0->nal_unit_type == NAL_IDR_SLICE){",
"s->broken_link= get_bits1(&s->gb) -1;",
"VAR_0->mmco[0].long_index= get_bits1(&s->gb) - 1;",
"if(VAR_0->mmco[0].long_index == -1)\nVAR_0->mmco_index= 0;",
"el... | [
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1
],
[
3
],
[
5
],
[
9
],
[
11
],
[
13
],
[
15,
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
37
],
[
39
],
[
41
],
[
51
],
[
53... |
10,775 | static DeviceState *sbi_init(target_phys_addr_t addr, qemu_irq **parent_irq)
{
DeviceState *dev;
SysBusDevice *s;
unsigned int i;
dev = qdev_create(NULL, "sbi");
qdev_init(dev);
s = sysbus_from_qdev(dev);
for (i = 0; i < MAX_CPUS; i++) {
sysbus_connect_irq(s, i, *paren... | true | qemu | e23a1b33b53d25510320b26d9f154e19c6c99725 | static DeviceState *sbi_init(target_phys_addr_t addr, qemu_irq **parent_irq)
{
DeviceState *dev;
SysBusDevice *s;
unsigned int i;
dev = qdev_create(NULL, "sbi");
qdev_init(dev);
s = sysbus_from_qdev(dev);
for (i = 0; i < MAX_CPUS; i++) {
sysbus_connect_irq(s, i, *paren... | {
"code": [
" qdev_init(dev);",
" qdev_init(dev);",
" qdev_init(dev);",
" qdev_init(dev);",
" qdev_init(dev);",
" qdev_init(dev);",
" qdev_init(dev);",
" qdev_init(dev);",
" qdev_init(dev);",
" qdev_init(dev);",
" qdev_init(dev);",
" ... | static DeviceState *FUNC_0(target_phys_addr_t addr, qemu_irq **parent_irq)
{
DeviceState *dev;
SysBusDevice *s;
unsigned int VAR_0;
dev = qdev_create(NULL, "sbi");
qdev_init(dev);
s = sysbus_from_qdev(dev);
for (VAR_0 = 0; VAR_0 < MAX_CPUS; VAR_0++) {
sysbus_connect_ir... | [
"static DeviceState *FUNC_0(target_phys_addr_t addr, qemu_irq **parent_irq)\n{",
"DeviceState *dev;",
"SysBusDevice *s;",
"unsigned int VAR_0;",
"dev = qdev_create(NULL, \"sbi\");",
"qdev_init(dev);",
"s = sysbus_from_qdev(dev);",
"for (VAR_0 = 0; VAR_0 < MAX_CPUS; VAR_0++) {",
"sysbus_connect_irq(s... | [
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
19
],
[
23
],
[
25
],
[
27
],
[
31
],
[
35
],
[
37
]
] |
10,776 | void qdist_add(struct qdist *dist, double x, long count)
{
struct qdist_entry *entry = NULL;
if (dist->n) {
struct qdist_entry e;
e.x = x;
entry = bsearch(&e, dist->entries, dist->n, sizeof(e), qdist_cmp);
}
if (entry) {
entry->count += count;
retu... | true | qemu | 071d4054770205ddb8a58a9e2735069d8fe52af1 | void qdist_add(struct qdist *dist, double x, long count)
{
struct qdist_entry *entry = NULL;
if (dist->n) {
struct qdist_entry e;
e.x = x;
entry = bsearch(&e, dist->entries, dist->n, sizeof(e), qdist_cmp);
}
if (entry) {
entry->count += count;
retu... | {
"code": [
" dist->entries = g_realloc(dist->entries,",
" sizeof(*dist->entries) * (dist->size));"
],
"line_no": [
37,
39
]
} | void FUNC_0(struct qdist *VAR_0, double VAR_1, long VAR_2)
{
struct qdist_entry *VAR_3 = NULL;
if (VAR_0->n) {
struct qdist_entry VAR_4;
VAR_4.VAR_1 = VAR_1;
VAR_3 = bsearch(&VAR_4, VAR_0->entries, VAR_0->n, sizeof(VAR_4), qdist_cmp);
}
if (VAR_3) {
VAR_3->... | [
"void FUNC_0(struct qdist *VAR_0, double VAR_1, long VAR_2)\n{",
"struct qdist_entry *VAR_3 = NULL;",
"if (VAR_0->n) {",
"struct qdist_entry VAR_4;",
"VAR_4.VAR_1 = VAR_1;",
"VAR_3 = bsearch(&VAR_4, VAR_0->entries, VAR_0->n, sizeof(VAR_4), qdist_cmp);",
"}",
"if (VAR_3) {",
"VAR_3->VAR_2 += VAR_2;",... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
],
[
15
],
[
17
],
[
19
],
[
23
],
[
25
],
[
27
],
[
29
],
[
33
],
[
35
],
[
37,
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49
],
... |
10,777 | static void av_always_inline filter_mb_edgeh( uint8_t *pix, int stride, const int16_t bS[4], unsigned int qp, H264Context *h ) {
const int qp_bd_offset = 6 * (h->sps.bit_depth_luma - 8);
const unsigned int index_a = qp - qp_bd_offset + h->slice_alpha_c0_offset;
const int alpha = alpha_table[index_a];
... | false | FFmpeg | a4f6be86d67ae30d494fbe8a470bc32b715d75a9 | static void av_always_inline filter_mb_edgeh( uint8_t *pix, int stride, const int16_t bS[4], unsigned int qp, H264Context *h ) {
const int qp_bd_offset = 6 * (h->sps.bit_depth_luma - 8);
const unsigned int index_a = qp - qp_bd_offset + h->slice_alpha_c0_offset;
const int alpha = alpha_table[index_a];
... | {
"code": [],
"line_no": []
} | static void VAR_0 filter_mb_edgeh( uint8_t *pix, int stride, const int16_t bS[4], unsigned int qp, H264Context *h ) {
const int qp_bd_offset = 6 * (h->sps.bit_depth_luma - 8);
const unsigned int index_a = qp - qp_bd_offset + h->slice_alpha_c0_offset;
const int alpha = alpha_table[index_a];
const int... | [
"static void VAR_0 filter_mb_edgeh( uint8_t *pix, int stride, const int16_t bS[4], unsigned int qp, H264Context *h ) {",
"const int qp_bd_offset = 6 * (h->sps.bit_depth_luma - 8);",
"const unsigned int index_a = qp - qp_bd_offset + h->slice_alpha_c0_offset;",
"const int alpha = alpha_table[index_a];",
"cons... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1
],
[
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
]
] |
10,779 | static int decode_residual(H264Context *h, GetBitContext *gb, DCTELEM *block, int n, const uint8_t *scantable, int qp, int max_coeff){
MpegEncContext * const s = &h->s;
const uint16_t *qmul= dequant_coeff[qp];
static const int coeff_token_table_index[17]= {0, 0, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, ... | false | FFmpeg | 980a82b70baa754ce120ffe9a4ce9e66ea14edba | static int decode_residual(H264Context *h, GetBitContext *gb, DCTELEM *block, int n, const uint8_t *scantable, int qp, int max_coeff){
MpegEncContext * const s = &h->s;
const uint16_t *qmul= dequant_coeff[qp];
static const int coeff_token_table_index[17]= {0, 0, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, ... | {
"code": [],
"line_no": []
} | static int FUNC_0(H264Context *VAR_0, GetBitContext *VAR_1, DCTELEM *VAR_2, int VAR_3, const uint8_t *VAR_4, int VAR_5, int VAR_6){
MpegEncContext * const s = &VAR_0->s;
const uint16_t *VAR_7= dequant_coeff[VAR_5];
static const int VAR_8[17]= {0, 0, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3};
int ... | [
"static int FUNC_0(H264Context *VAR_0, GetBitContext *VAR_1, DCTELEM *VAR_2, int VAR_3, const uint8_t *VAR_4, int VAR_5, int VAR_6){",
"MpegEncContext * const s = &VAR_0->s;",
"const uint16_t *VAR_7= dequant_coeff[VAR_5];",
"static const int VAR_8[17]= {0, 0, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3};",
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[... |
10,780 | static void spapr_phb_vfio_finish_realize(sPAPRPHBState *sphb, Error **errp)
{
sPAPRPHBVFIOState *svphb = SPAPR_PCI_VFIO_HOST_BRIDGE(sphb);
struct vfio_iommu_spapr_tce_info info = { .argsz = sizeof(info) };
int ret;
sPAPRTCETable *tcet;
uint32_t liobn = svphb->phb.dma_liobn;
if (svphb->... | true | qemu | 72700d7e733948fa7fbb735ccdf2209931c88476 | static void spapr_phb_vfio_finish_realize(sPAPRPHBState *sphb, Error **errp)
{
sPAPRPHBVFIOState *svphb = SPAPR_PCI_VFIO_HOST_BRIDGE(sphb);
struct vfio_iommu_spapr_tce_info info = { .argsz = sizeof(info) };
int ret;
sPAPRTCETable *tcet;
uint32_t liobn = svphb->phb.dma_liobn;
if (svphb->... | {
"code": [
"static void spapr_phb_vfio_finish_realize(sPAPRPHBState *sphb, Error **errp)",
" sPAPRPHBVFIOState *svphb = SPAPR_PCI_VFIO_HOST_BRIDGE(sphb);",
" struct vfio_iommu_spapr_tce_info info = { .argsz = sizeof(info) };",
" int ret;",
" sPAPRTCETable *tcet;",
" uint32_t li... | static void FUNC_0(sPAPRPHBState *VAR_0, Error **VAR_1)
{
sPAPRPHBVFIOState *svphb = SPAPR_PCI_VFIO_HOST_BRIDGE(VAR_0);
struct vfio_iommu_spapr_tce_info VAR_2 = { .argsz = sizeof(VAR_2) };
int VAR_3;
sPAPRTCETable *tcet;
uint32_t liobn = svphb->phb.dma_liobn;
if (svphb->iommugroupid == ... | [
"static void FUNC_0(sPAPRPHBState *VAR_0, Error **VAR_1)\n{",
"sPAPRPHBVFIOState *svphb = SPAPR_PCI_VFIO_HOST_BRIDGE(VAR_0);",
"struct vfio_iommu_spapr_tce_info VAR_2 = { .argsz = sizeof(VAR_2) };",
"int VAR_3;",
"sPAPRTCETable *tcet;",
"uint32_t liobn = svphb->phb.dma_liobn;",
"if (svphb->iommugroupid ... | [
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
1,
1,
1,
0,
0,
1,
1,
1,
0,
0,
1,
1,
1,
0,
0,
1,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
17
],
[
19
],
[
21
],
[
23
],
[
27,
29,
31
],
[
33
],
[
35,
37
],
[
39
],
[
41
],
[
45,
47
],
[
49
],
[
51,... |
10,781 | static int coroutine_fn bdrv_mirror_top_flush(BlockDriverState *bs)
{
return bdrv_co_flush(bs->backing->bs);
| true | qemu | ce960aa9062a407d0ca15aee3dcd3bd84a4e24f9 | static int coroutine_fn bdrv_mirror_top_flush(BlockDriverState *bs)
{
return bdrv_co_flush(bs->backing->bs);
| {
"code": [],
"line_no": []
} | static int VAR_0 bdrv_mirror_top_flush(BlockDriverState *bs)
{
return bdrv_co_flush(bs->backing->bs);
| [
"static int VAR_0 bdrv_mirror_top_flush(BlockDriverState *bs)\n{",
"return bdrv_co_flush(bs->backing->bs);"
] | [
0,
0
] | [
[
1,
3
],
[
9
]
] |
10,782 | static int mov_read_stss(MOVContext *c, ByteIOContext *pb, MOV_atom_t atom)
{
AVStream *st = c->fc->streams[c->fc->nb_streams-1];
MOVStreamContext *sc = (MOVStreamContext *)st->priv_data;
int entries, i;
print_atom("stss", atom);
get_byte(pb); /* version */
get_byte(pb); get_byte(pb);... | true | FFmpeg | 568e18b15e2ddf494fd8926707d34ca08c8edce5 | static int mov_read_stss(MOVContext *c, ByteIOContext *pb, MOV_atom_t atom)
{
AVStream *st = c->fc->streams[c->fc->nb_streams-1];
MOVStreamContext *sc = (MOVStreamContext *)st->priv_data;
int entries, i;
print_atom("stss", atom);
get_byte(pb);
get_byte(pb); get_byte(pb); get_byte(pb)... | {
"code": [
" int entries, i;",
" int entries, i;",
" int entries, i;",
" int entries, i;",
" int entries, i;"
],
"line_no": [
9,
9,
9,
9,
9
]
} | static int FUNC_0(MOVContext *VAR_0, ByteIOContext *VAR_1, MOV_atom_t VAR_2)
{
AVStream *st = VAR_0->fc->streams[VAR_0->fc->nb_streams-1];
MOVStreamContext *sc = (MOVStreamContext *)st->priv_data;
int VAR_3, VAR_4;
print_atom("stss", VAR_2);
get_byte(VAR_1);
get_byte(VAR_1); get_byte... | [
"static int FUNC_0(MOVContext *VAR_0, ByteIOContext *VAR_1, MOV_atom_t VAR_2)\n{",
"AVStream *st = VAR_0->fc->streams[VAR_0->fc->nb_streams-1];",
"MOVStreamContext *sc = (MOVStreamContext *)st->priv_data;",
"int VAR_3, VAR_4;",
"print_atom(\"stss\", VAR_2);",
"get_byte(VAR_1);",
"get_byte(VAR_1); get_by... | [
0,
0,
0,
1,
0,
0,
0,
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
],
[
39
],
[
41
],
[
43,
47,
49
],
[
51
],
[
53
]
] |
10,784 | static int concat_read_packet(AVFormatContext *avf, AVPacket *pkt)
{
ConcatContext *cat = avf->priv_data;
int ret;
int64_t delta;
while (1) {
if ((ret = av_read_frame(cat->avf, pkt)) != AVERROR_EOF ||
(ret = open_next_file(avf)) < 0)
break;
}
delta = av_rescale_q(... | true | FFmpeg | aeccb522ebb6fb0378bccd6393f1d0c1ca40fdd4 | static int concat_read_packet(AVFormatContext *avf, AVPacket *pkt)
{
ConcatContext *cat = avf->priv_data;
int ret;
int64_t delta;
while (1) {
if ((ret = av_read_frame(cat->avf, pkt)) != AVERROR_EOF ||
(ret = open_next_file(avf)) < 0)
break;
}
delta = av_rescale_q(... | {
"code": [],
"line_no": []
} | static int FUNC_0(AVFormatContext *VAR_0, AVPacket *VAR_1)
{
ConcatContext *cat = VAR_0->priv_data;
int VAR_2;
int64_t delta;
while (1) {
if ((VAR_2 = av_read_frame(cat->VAR_0, VAR_1)) != AVERROR_EOF ||
(VAR_2 = open_next_file(VAR_0)) < 0)
break;
}
delta = av_resc... | [
"static int FUNC_0(AVFormatContext *VAR_0, AVPacket *VAR_1)\n{",
"ConcatContext *cat = VAR_0->priv_data;",
"int VAR_2;",
"int64_t delta;",
"while (1) {",
"if ((VAR_2 = av_read_frame(cat->VAR_0, VAR_1)) != AVERROR_EOF ||\n(VAR_2 = open_next_file(VAR_0)) < 0)\nbreak;",
"}",
"delta = av_rescale_q(cat->cu... | [
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
]
] |
10,785 | static coroutine_fn int qcow2_co_flush_to_os(BlockDriverState *bs)
{
BDRVQcowState *s = bs->opaque;
int ret;
qemu_co_mutex_lock(&s->lock);
ret = qcow2_cache_flush(bs, s->l2_table_cache);
if (ret < 0) {
qemu_co_mutex_unlock(&s->lock);
return ret;
}
ret = qcow2_ca... | true | qemu | bfe8043e9214d2fc6572cc72b5f2218308747acd | static coroutine_fn int qcow2_co_flush_to_os(BlockDriverState *bs)
{
BDRVQcowState *s = bs->opaque;
int ret;
qemu_co_mutex_lock(&s->lock);
ret = qcow2_cache_flush(bs, s->l2_table_cache);
if (ret < 0) {
qemu_co_mutex_unlock(&s->lock);
return ret;
}
ret = qcow2_ca... | {
"code": [
" ret = qcow2_cache_flush(bs, s->refcount_block_cache);",
" if (ret < 0) {",
" qemu_co_mutex_unlock(&s->lock);",
" return ret;"
],
"line_no": [
25,
15,
17,
19
]
} | static coroutine_fn int FUNC_0(BlockDriverState *bs)
{
BDRVQcowState *s = bs->opaque;
int VAR_0;
qemu_co_mutex_lock(&s->lock);
VAR_0 = qcow2_cache_flush(bs, s->l2_table_cache);
if (VAR_0 < 0) {
qemu_co_mutex_unlock(&s->lock);
return VAR_0;
}
VAR_0 = qcow2_cache_... | [
"static coroutine_fn int FUNC_0(BlockDriverState *bs)\n{",
"BDRVQcowState *s = bs->opaque;",
"int VAR_0;",
"qemu_co_mutex_lock(&s->lock);",
"VAR_0 = qcow2_cache_flush(bs, s->l2_table_cache);",
"if (VAR_0 < 0) {",
"qemu_co_mutex_unlock(&s->lock);",
"return VAR_0;",
"}",
"VAR_0 = qcow2_cache_flush(b... | [
0,
0,
0,
0,
0,
1,
1,
1,
0,
1,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
25
],
[
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
39
],
[
41
]
] |
10,786 | static inline void RENAME(rgb24ToY)(uint8_t *dst, const uint8_t *src, int width, uint32_t *unused)
{
#if COMPILE_TEMPLATE_MMX
RENAME(bgr24ToY_mmx)(dst, src, width, PIX_FMT_RGB24);
#else
int i;
for (i=0; i<width; i++) {
int r= src[i*3+0];
int g= src[i*3+1];
int b= src[i*3+2];... | true | FFmpeg | c3ab0004ae4dffc32494ae84dd15cfaa909a7884 | static inline void RENAME(rgb24ToY)(uint8_t *dst, const uint8_t *src, int width, uint32_t *unused)
{
#if COMPILE_TEMPLATE_MMX
RENAME(bgr24ToY_mmx)(dst, src, width, PIX_FMT_RGB24);
#else
int i;
for (i=0; i<width; i++) {
int r= src[i*3+0];
int g= src[i*3+1];
int b= src[i*3+2];... | {
"code": [
"static inline void RENAME(rgb24ToY)(uint8_t *dst, const uint8_t *src, int width, uint32_t *unused)"
],
"line_no": [
1
]
} | static inline void FUNC_0(rgb24ToY)(uint8_t *dst, const uint8_t *src, int width, uint32_t *unused)
{
#if COMPILE_TEMPLATE_MMX
FUNC_0(bgr24ToY_mmx)(dst, src, width, PIX_FMT_RGB24);
#else
int VAR_0;
for (VAR_0=0; VAR_0<width; VAR_0++) {
int r= src[VAR_0*3+0];
int g= src[VAR_0*3+1];
... | [
"static inline void FUNC_0(rgb24ToY)(uint8_t *dst, const uint8_t *src, int width, uint32_t *unused)\n{",
"#if COMPILE_TEMPLATE_MMX\nFUNC_0(bgr24ToY_mmx)(dst, src, width, PIX_FMT_RGB24);",
"#else\nint VAR_0;",
"for (VAR_0=0; VAR_0<width; VAR_0++) {",
"int r= src[VAR_0*3+0];",
"int g= src[VAR_0*3+1];",
"i... | [
1,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5,
7
],
[
9,
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
23
],
[
25
],
[
27,
29
]
] |
10,787 | static inline void RENAME(rgb16to32)(const uint8_t *src, uint8_t *dst, int src_size)
{
const uint16_t *end;
const uint16_t *mm_end;
uint8_t *d = dst;
const uint16_t *s = (const uint16_t*)src;
end = s + src_size/2;
__asm__ volatile(PREFETCH" %0"::"m"(*s):"memory");
__asm__ volatile... | true | FFmpeg | 90540c2d5ace46a1e9789c75fde0b1f7dbb12a9b | static inline void RENAME(rgb16to32)(const uint8_t *src, uint8_t *dst, int src_size)
{
const uint16_t *end;
const uint16_t *mm_end;
uint8_t *d = dst;
const uint16_t *s = (const uint16_t*)src;
end = s + src_size/2;
__asm__ volatile(PREFETCH" %0"::"m"(*s):"memory");
__asm__ volatile... | {
"code": [
" PREFETCH\" 32%1 \\n\\t\"",
" PREFETCH\" 32%1 \\n\\t\"",
" \"movq %1, %%mm0 \\n\\t\"",
" :\"=m\"(*d)",
" :\"=m\"(*d)",
" PREFETCH\" 32%1 \\n\\t\"",
" ... | static inline void FUNC_0(rgb16to32)(const uint8_t *src, uint8_t *dst, int src_size)
{
const uint16_t *VAR_0;
const uint16_t *VAR_1;
uint8_t *d = dst;
const uint16_t *VAR_2 = (const uint16_t*)src;
VAR_0 = VAR_2 + src_size/2;
__asm__ volatile(PREFETCH" %0"::"m"(*VAR_2):"memory");
_... | [
"static inline void FUNC_0(rgb16to32)(const uint8_t *src, uint8_t *dst, int src_size)\n{",
"const uint16_t *VAR_0;",
"const uint16_t *VAR_1;",
"uint8_t *d = dst;",
"const uint16_t *VAR_2 = (const uint16_t*)src;",
"VAR_0 = VAR_2 + src_size/2;",
"__asm__ volatile(PREFETCH\" %0\"::\"m\"(*VAR_2):\"memory... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
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
... |
10,788 | void helper_sysret(CPUX86State *env, int dflag)
{
int cpl, selector;
if (!(env->efer & MSR_EFER_SCE)) {
raise_exception_err(env, EXCP06_ILLOP, 0);
}
cpl = env->hflags & HF_CPL_MASK;
if (!(env->cr[0] & CR0_PE_MASK) || cpl != 0) {
raise_exception_err(env, EXCP0D_GPF, 0);
... | true | qemu | ac57622985220de064059971f9ccb00905e9bd04 | void helper_sysret(CPUX86State *env, int dflag)
{
int cpl, selector;
if (!(env->efer & MSR_EFER_SCE)) {
raise_exception_err(env, EXCP06_ILLOP, 0);
}
cpl = env->hflags & HF_CPL_MASK;
if (!(env->cr[0] & CR0_PE_MASK) || cpl != 0) {
raise_exception_err(env, EXCP0D_GPF, 0);
... | {
"code": [
" cpu_x86_load_seg_cache(env, R_SS, selector + 8,",
" cpu_x86_load_seg_cache(env, R_SS, selector + 8,"
],
"line_no": [
65,
65
]
} | void FUNC_0(CPUX86State *VAR_0, int VAR_1)
{
int VAR_2, VAR_3;
if (!(VAR_0->efer & MSR_EFER_SCE)) {
raise_exception_err(VAR_0, EXCP06_ILLOP, 0);
}
VAR_2 = VAR_0->hflags & HF_CPL_MASK;
if (!(VAR_0->cr[0] & CR0_PE_MASK) || VAR_2 != 0) {
raise_exception_err(VAR_0, EXCP0D_GPF, ... | [
"void FUNC_0(CPUX86State *VAR_0, int VAR_1)\n{",
"int VAR_2, VAR_3;",
"if (!(VAR_0->efer & MSR_EFER_SCE)) {",
"raise_exception_err(VAR_0, EXCP06_ILLOP, 0);",
"}",
"VAR_2 = VAR_0->hflags & HF_CPL_MASK;",
"if (!(VAR_0->cr[0] & CR0_PE_MASK) || VAR_2 != 0) {",
"raise_exception_err(VAR_0, EXCP0D_GPF, 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
] | [
[
1,
3
],
[
5
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27,
29,
31
],
[
33
],
[
35,
37,
39,
41,
43,
45
],
[
47
],
[
49
],
... |
10,789 | static av_cold int adx_encode_init(AVCodecContext *avctx)
{
ADXContext *c = avctx->priv_data;
if (avctx->channels > 2)
return -1;
avctx->frame_size = 32;
avctx->coded_frame = avcodec_alloc_frame();
avctx->coded_frame->key_frame = 1;
/* the cutoff can be adjusted, but this s... | false | FFmpeg | cc40c056d01a95b0a57950d4d8aec9e86060c6b6 | static av_cold int adx_encode_init(AVCodecContext *avctx)
{
ADXContext *c = avctx->priv_data;
if (avctx->channels > 2)
return -1;
avctx->frame_size = 32;
avctx->coded_frame = avcodec_alloc_frame();
avctx->coded_frame->key_frame = 1;
c->cutoff = 500;
ff_adx_calcul... | {
"code": [],
"line_no": []
} | static av_cold int FUNC_0(AVCodecContext *avctx)
{
ADXContext *c = avctx->priv_data;
if (avctx->channels > 2)
return -1;
avctx->frame_size = 32;
avctx->coded_frame = avcodec_alloc_frame();
avctx->coded_frame->key_frame = 1;
c->cutoff = 500;
ff_adx_calculate_coeff... | [
"static av_cold int FUNC_0(AVCodecContext *avctx)\n{",
"ADXContext *c = avctx->priv_data;",
"if (avctx->channels > 2)\nreturn -1;",
"avctx->frame_size = 32;",
"avctx->coded_frame = avcodec_alloc_frame();",
"avctx->coded_frame->key_frame = 1;",
"c->cutoff = 500;",
"ff_adx_calculate_coeffs(c->cutoff, av... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9,
11
],
[
13
],
[
17
],
[
19
],
[
25
],
[
27
],
[
31
],
[
33
]
] |
10,790 | static int mpegps_read_header(AVFormatContext *s,
AVFormatParameters *ap)
{
MpegDemuxContext *m = s->priv_data;
uint8_t buffer[8192];
char *p;
m->header_state = 0xff;
s->ctx_flags |= AVFMTCTX_NOHEADER;
get_buffer(&s->pb, buffer, sizeof(buffer));
if ... | false | FFmpeg | cc04af3481438e74278fff4532a0956363155708 | static int mpegps_read_header(AVFormatContext *s,
AVFormatParameters *ap)
{
MpegDemuxContext *m = s->priv_data;
uint8_t buffer[8192];
char *p;
m->header_state = 0xff;
s->ctx_flags |= AVFMTCTX_NOHEADER;
get_buffer(&s->pb, buffer, sizeof(buffer));
if ... | {
"code": [],
"line_no": []
} | static int FUNC_0(AVFormatContext *VAR_0,
AVFormatParameters *VAR_1)
{
MpegDemuxContext *m = VAR_0->priv_data;
uint8_t buffer[8192];
char *VAR_2;
m->header_state = 0xff;
VAR_0->ctx_flags |= AVFMTCTX_NOHEADER;
get_buffer(&VAR_0->pb, buffer, sizeof(buffer)... | [
"static int FUNC_0(AVFormatContext *VAR_0,\nAVFormatParameters *VAR_1)\n{",
"MpegDemuxContext *m = VAR_0->priv_data;",
"uint8_t buffer[8192];",
"char *VAR_2;",
"m->header_state = 0xff;",
"VAR_0->ctx_flags |= AVFMTCTX_NOHEADER;",
"get_buffer(&VAR_0->pb, buffer, sizeof(buffer));",
"if ((VAR_2=memchr(buf... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
15
],
[
17
],
[
21
],
[
23,
25,
27
],
[
29
],
[
35
],
[
37
]
] |
10,791 | int get_frame_filename(char *buf, int buf_size,
const char *path, int number)
{
const char *p;
char *q, buf1[20];
int nd, len, c, percentd_found;
q = buf;
p = path;
percentd_found = 0;
for(;;) {
c = *p++;
if (c == '\0')
break;
... | false | FFmpeg | 22b37f5d3200cfe4c15eded883663cf0612093c1 | int get_frame_filename(char *buf, int buf_size,
const char *path, int number)
{
const char *p;
char *q, buf1[20];
int nd, len, c, percentd_found;
q = buf;
p = path;
percentd_found = 0;
for(;;) {
c = *p++;
if (c == '\0')
break;
... | {
"code": [],
"line_no": []
} | int FUNC_0(char *VAR_0, int VAR_1,
const char *VAR_2, int VAR_3)
{
const char *VAR_4;
char *VAR_5, VAR_6[20];
int VAR_7, VAR_8, VAR_9, VAR_10;
VAR_5 = VAR_0;
VAR_4 = VAR_2;
VAR_10 = 0;
for(;;) {
VAR_9 = *VAR_4++;
if (VAR_9 == '\0')
... | [
"int FUNC_0(char *VAR_0, int VAR_1,\nconst char *VAR_2, int VAR_3)\n{",
"const char *VAR_4;",
"char *VAR_5, VAR_6[20];",
"int VAR_7, VAR_8, VAR_9, VAR_10;",
"VAR_5 = VAR_0;",
"VAR_4 = VAR_2;",
"VAR_10 = 0;",
"for(;;) {",
"VAR_9 = *VAR_4++;",
"if (VAR_9 == '\\0')\nbreak;",
"if (VAR_9 == '%') {",
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25,
27
],
[
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
47
... |
10,792 | static int ivi_decode_blocks(GetBitContext *gb, IVIBandDesc *band, IVITile *tile,
AVCodecContext *avctx)
{
int mbn, blk, num_blocks, num_coeffs, blk_size, scan_pos, run, val,
pos, is_intra, mc_type = 0, mv_x, mv_y, col_mask;
uint8_t col_flags[8];
... | true | FFmpeg | 30872fa09be99a0af65d14f28c0c5d91120065f0 | static int ivi_decode_blocks(GetBitContext *gb, IVIBandDesc *band, IVITile *tile,
AVCodecContext *avctx)
{
int mbn, blk, num_blocks, num_coeffs, blk_size, scan_pos, run, val,
pos, is_intra, mc_type = 0, mv_x, mv_y, col_mask;
uint8_t col_flags[8];
... | {
"code": [
" pos, is_intra, mc_type = 0, mv_x, mv_y, col_mask;",
" uint32_t cbp, sym, lo, hi, quant, buf_offs, q;"
],
"line_no": [
9,
15
]
} | static int FUNC_0(GetBitContext *VAR_0, IVIBandDesc *VAR_1, IVITile *VAR_2,
AVCodecContext *VAR_3)
{
int VAR_4, VAR_5, VAR_6, VAR_7, VAR_8, VAR_9, VAR_10, VAR_11,
VAR_12, VAR_13, VAR_23 = 0, VAR_15, VAR_16, VAR_17;
uint8_t col_flags[8];
int32_t ... | [
"static int FUNC_0(GetBitContext *VAR_0, IVIBandDesc *VAR_1, IVITile *VAR_2,\nAVCodecContext *VAR_3)\n{",
"int VAR_4, VAR_5, VAR_6, VAR_7, VAR_8, VAR_9, VAR_10, VAR_11,\nVAR_12, VAR_13, VAR_23 = 0, VAR_15, VAR_16, VAR_17;",
"uint8_t col_flags[8];",
"int32_t prev_dc, trvec[64];",
"uint32_t ... | [
0,
1,
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,
0,
0,
0... | [
[
1,
3,
5
],
[
7,
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
31
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
... |
10,793 | static inline int handle_cpu_signal(uintptr_t pc, unsigned long address,
int is_write, sigset_t *old_set)
{
CPUState *cpu;
CPUClass *cc;
int ret;
#if defined(DEBUG_SIGNAL)
printf("qemu: SIGSEGV pc=0x%08lx address=%08lx w=%d oldset=0x%08lx\n",
pc, ... | true | qemu | 02bed6bd5f45819f1557a4b04db300a72383ecdb | static inline int handle_cpu_signal(uintptr_t pc, unsigned long address,
int is_write, sigset_t *old_set)
{
CPUState *cpu;
CPUClass *cc;
int ret;
#if defined(DEBUG_SIGNAL)
printf("qemu: SIGSEGV pc=0x%08lx address=%08lx w=%d oldset=0x%08lx\n",
pc, ... | {
"code": [
" CPUState *cpu;",
" cpu_exit_tb_from_sighandler(current_cpu, old_set);",
" cpu = current_cpu;"
],
"line_no": [
7,
59,
81
]
} | static inline int FUNC_0(uintptr_t VAR_0, unsigned long VAR_1,
int VAR_2, sigset_t *VAR_3)
{
CPUState *cpu;
CPUClass *cc;
int VAR_4;
#if defined(DEBUG_SIGNAL)
printf("qemu: SIGSEGV VAR_0=0x%08lx VAR_1=%08lx w=%d oldset=0x%08lx\n",
VAR_0, VAR_1, VA... | [
"static inline int FUNC_0(uintptr_t VAR_0, unsigned long VAR_1,\nint VAR_2, sigset_t *VAR_3)\n{",
"CPUState *cpu;",
"CPUClass *cc;",
"int VAR_4;",
"#if defined(DEBUG_SIGNAL)\nprintf(\"qemu: SIGSEGV VAR_0=0x%08lx VAR_1=%08lx w=%d oldset=0x%08lx\\n\",\nVAR_0, VAR_1, VAR_2, *(unsigned long *)VAR_3);",
"#endi... | [
0,
1,
0,
0,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
15,
17,
19
],
[
21,
25
],
[
27
],
[
29,
37
],
[
39,
47
],
[
49,
59
],
[
61
],
[
63,
65
],
[
67
],
[
69
],
[
77
],
[
81
... |
10,794 | static void put_bool(QEMUFile *f, void *pv, size_t size)
{
bool *v = pv;
qemu_put_byte(f, *v);
}
| true | qemu | 60fe637bf0e4d7989e21e50f52526444765c63b4 | static void put_bool(QEMUFile *f, void *pv, size_t size)
{
bool *v = pv;
qemu_put_byte(f, *v);
}
| {
"code": [],
"line_no": []
} | static void FUNC_0(QEMUFile *VAR_0, void *VAR_1, size_t VAR_2)
{
bool *v = VAR_1;
qemu_put_byte(VAR_0, *v);
}
| [
"static void FUNC_0(QEMUFile *VAR_0, void *VAR_1, size_t VAR_2)\n{",
"bool *v = VAR_1;",
"qemu_put_byte(VAR_0, *v);",
"}"
] | [
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
]
] |
10,795 | static void uhci_frame_timer(void *opaque)
{
UHCIState *s = opaque;
/* prepare the timer for the next frame */
s->expire_time += (get_ticks_per_sec() / FRAME_TIMER_FREQ);
s->frame_bytes = 0;
s->completions_only = false;
qemu_bh_cancel(s->bh);
if (!(s->cmd & UHCI_CMD_RS)) {
... | true | qemu | f8f48b6957bf182339495e6be429f7bdc7ef1981 | static void uhci_frame_timer(void *opaque)
{
UHCIState *s = opaque;
s->expire_time += (get_ticks_per_sec() / FRAME_TIMER_FREQ);
s->frame_bytes = 0;
s->completions_only = false;
qemu_bh_cancel(s->bh);
if (!(s->cmd & UHCI_CMD_RS)) {
trace_usb_uhci_schedule_stop(... | {
"code": [
" s->expire_time += (get_ticks_per_sec() / FRAME_TIMER_FREQ);",
" s->frame_bytes = 0;",
" trace_usb_uhci_frame_start(s->frnum);",
" uhci_async_validate_begin(s);",
" uhci_process_frame(s);",
" uhci_async_validate_end(s);",
" s->frnum = (s->frnum + 1) & 0x7f... | static void FUNC_0(void *VAR_0)
{
UHCIState *s = VAR_0;
s->expire_time += (get_ticks_per_sec() / FRAME_TIMER_FREQ);
s->frame_bytes = 0;
s->completions_only = false;
qemu_bh_cancel(s->bh);
if (!(s->cmd & UHCI_CMD_RS)) {
trace_usb_uhci_schedule_stop();
... | [
"static void FUNC_0(void *VAR_0)\n{",
"UHCIState *s = VAR_0;",
"s->expire_time += (get_ticks_per_sec() / FRAME_TIMER_FREQ);",
"s->frame_bytes = 0;",
"s->completions_only = false;",
"qemu_bh_cancel(s->bh);",
"if (!(s->cmd & UHCI_CMD_RS)) {",
"trace_usb_uhci_schedule_stop();",
"qemu_del_timer(s->frame... | [
0,
0,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
1,
0
] | [
[
1,
3
],
[
5
],
[
11
],
[
13
],
[
15
],
[
17
],
[
21
],
[
25
],
[
27
],
[
29
],
[
33
],
[
35
],
[
37
],
[
43
],
[
47
],
[
51
],
[
55
],
[
63
],
[
69
],
[
7... |
10,796 | static TCGv gen_vfp_mrs(void)
{
TCGv tmp = new_tmp();
tcg_gen_mov_i32(tmp, cpu_F0s);
return tmp;
}
| true | qemu | 7d1b0095bff7157e856d1d0e6c4295641ced2752 | static TCGv gen_vfp_mrs(void)
{
TCGv tmp = new_tmp();
tcg_gen_mov_i32(tmp, cpu_F0s);
return tmp;
}
| {
"code": [
" TCGv tmp = new_tmp();",
" TCGv tmp = new_tmp();",
" TCGv tmp = new_tmp();",
" TCGv tmp = new_tmp();",
" TCGv tmp = new_tmp();",
" TCGv tmp = new_tmp();",
" TCGv tmp = new_tmp();",
" TCGv tmp = new_tmp();",
" TCGv tmp = new_tmp();",
" ... | static TCGv FUNC_0(void)
{
TCGv tmp = new_tmp();
tcg_gen_mov_i32(tmp, cpu_F0s);
return tmp;
}
| [
"static TCGv FUNC_0(void)\n{",
"TCGv tmp = new_tmp();",
"tcg_gen_mov_i32(tmp, cpu_F0s);",
"return tmp;",
"}"
] | [
0,
1,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
]
] |
10,797 | static int epzs_motion_search(MpegEncContext * s,
int *mx_ptr, int *my_ptr,
int P[5][2], int pred_x, int pred_y,
int xmin, int ymin, int xmax, int ymax)
{
int best[2]={0, 0};
int d, dmin;
UINT8 *new_pic, *old_pic;... | true | FFmpeg | 11ce88346b1ae4da21b581baf1b4eb784d842547 | static int epzs_motion_search(MpegEncContext * s,
int *mx_ptr, int *my_ptr,
int P[5][2], int pred_x, int pred_y,
int xmin, int ymin, int xmax, int ymax)
{
int best[2]={0, 0};
int d, dmin;
UINT8 *new_pic, *old_pic;... | {
"code": [
" dmin= small_diamond_search(s, best, dmin, new_pic, old_pic, pic_stride, ",
" pred_x, pred_y, mv_penalty, quant, xmin, ymin, xmax, ymax, shift);"
],
"line_no": [
87,
89
]
} | static int FUNC_0(MpegEncContext * VAR_0,
int *VAR_1, int *VAR_2,
int VAR_3[5][2], int VAR_4, int VAR_5,
int VAR_6, int VAR_7, int VAR_8, int VAR_9)
{
int VAR_10[2]={0, 0};
int VAR_11, VAR_12;
UINT8 *new_pic, *old... | [
"static int FUNC_0(MpegEncContext * VAR_0,\nint *VAR_1, int *VAR_2,\nint VAR_3[5][2], int VAR_4, int VAR_5,\nint VAR_6, int VAR_7, int VAR_8, int VAR_9)\n{",
"int VAR_10[2]={0, 0};",
"int VAR_11, VAR_12;",
"UINT8 *new_pic, *old_pic;",
"const int VAR_13= VAR_0->linesize;",
"const int VAR_14= (VAR_0->mb_y*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,
1,
0,
0,
0,
0
] | [
[
1,
3,
5,
7,
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
29
],
[
31
],
[
37
],
[
39
],
[
41
],
[
43
],
[
47
],
[
49
],
[
55
],
[... |
10,798 | void acpi_build(AcpiBuildTables *tables, MachineState *machine)
{
PCMachineState *pcms = PC_MACHINE(machine);
PCMachineClass *pcmc = PC_MACHINE_GET_CLASS(pcms);
GArray *table_offsets;
unsigned facs, dsdt, rsdt, fadt;
AcpiPmInfo pm;
AcpiMiscInfo misc;
AcpiMcfgInfo mcfg;
Range pci... | true | qemu | 75b0713e189a981e5bfd087d5f35705446bbb12a | void acpi_build(AcpiBuildTables *tables, MachineState *machine)
{
PCMachineState *pcms = PC_MACHINE(machine);
PCMachineClass *pcmc = PC_MACHINE_GET_CLASS(pcms);
GArray *table_offsets;
unsigned facs, dsdt, rsdt, fadt;
AcpiPmInfo pm;
AcpiMiscInfo misc;
AcpiMcfgInfo mcfg;
Range pci... | {
"code": [
" pcms->acpi_nvdimm_state.dsm_mem, machine->ram_slots);"
],
"line_no": [
181
]
} | void FUNC_0(AcpiBuildTables *VAR_0, MachineState *VAR_1)
{
PCMachineState *pcms = PC_MACHINE(VAR_1);
PCMachineClass *pcmc = PC_MACHINE_GET_CLASS(pcms);
GArray *table_offsets;
unsigned VAR_2, VAR_3, VAR_4, VAR_5;
AcpiPmInfo pm;
AcpiMiscInfo misc;
AcpiMcfgInfo mcfg;
Range pci_hole... | [
"void FUNC_0(AcpiBuildTables *VAR_0, MachineState *VAR_1)\n{",
"PCMachineState *pcms = PC_MACHINE(VAR_1);",
"PCMachineClass *pcmc = PC_MACHINE_GET_CLASS(pcms);",
"GArray *table_offsets;",
"unsigned VAR_2, VAR_3, VAR_4, VAR_5;",
"AcpiPmInfo pm;",
"AcpiMiscInfo misc;",
"AcpiMcfgInfo mcfg;",
"Range pci... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0... | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
31
],
[
33
],
[
35
],
[
37
],
[
41,
43
],
[
45
],
[... |
10,799 | void ff_snow_horizontal_compose97i_sse2(DWTELEM *b, int width){
const int w2= (width+1)>>1;
// SSE2 code runs faster with pointers aligned on a 32-byte boundary.
DWTELEM temp_buf[(width>>1) + 4];
DWTELEM * const temp = temp_buf + 4 - (((int)temp_buf & 0xF) >> 2);
const int w_l= (width>>1);
... | true | FFmpeg | 3e0f7126b53b395d9e79df57b2e626eb99ad846b | void ff_snow_horizontal_compose97i_sse2(DWTELEM *b, int width){
const int w2= (width+1)>>1;
DWTELEM temp_buf[(width>>1) + 4];
DWTELEM * const temp = temp_buf + 4 - (((int)temp_buf & 0xF) >> 2);
const int w_l= (width>>1);
const int w_r= w2 - 1;
int i;
{
DWTELEM * cons... | {
"code": [
"void ff_snow_horizontal_compose97i_sse2(DWTELEM *b, int width){",
" DWTELEM temp_buf[(width>>1) + 4];",
" DWTELEM * const temp = temp_buf + 4 - (((int)temp_buf & 0xF) >> 2);",
" DWTELEM * const ref = b + w2 - 1;",
" \"pslld $31, %%xmm7 \\n\\t\"",... | void FUNC_0(DWTELEM *VAR_0, int VAR_1){
const int VAR_2= (VAR_1+1)>>1;
DWTELEM temp_buf[(VAR_1>>1) + 4];
DWTELEM * const temp = temp_buf + 4 - (((int)temp_buf & 0xF) >> 2);
const int VAR_3= (VAR_1>>1);
const int VAR_4= VAR_2 - 1;
int VAR_5;
{
DWTELEM * const ref = VA... | [
"void FUNC_0(DWTELEM *VAR_0, int VAR_1){",
"const int VAR_2= (VAR_1+1)>>1;",
"DWTELEM temp_buf[(VAR_1>>1) + 4];",
"DWTELEM * const temp = temp_buf + 4 - (((int)temp_buf & 0xF) >> 2);",
"const int VAR_3= (VAR_1>>1);",
"const int VAR_4= VAR_2 - 1;",
"int VAR_5;",
"{",
"DWTELEM * const ref = VAR_0 + VA... | [
1,
0,
1,
1,
0,
0,
0,
0,
1,
0,
0,
1,
1,
1,
0,
0,
0,
0,
0,
1,
0,
1,
0,
0,
1,
0,
0,
0,
0,
0,
1,
1,
0,
1,
0,
1,
0,
0,
0,
0,
0,
1,
0,
1,
0,
0,
0,
1,
0,
0,
0,
0,
0,
1,
0,
0,
0,
1,
1,
0,
0,
0
] | [
[
1
],
[
3
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
19
],
[
21
],
[
23
],
[
33
],
[
35,
37,
39,
41,
43
],
[
45
],
[
47,
49,
51,
53,
55,
57,
59,
61,
63,
65... |
10,800 | PPC_OP(btest_T1)
{
if (T0) {
regs->nip = T1 & ~3;
} else {
regs->nip = PARAM1;
}
RETURN();
}
| true | qemu | d9bce9d99f4656ae0b0127f7472db9067b8f84ab | PPC_OP(btest_T1)
{
if (T0) {
regs->nip = T1 & ~3;
} else {
regs->nip = PARAM1;
}
RETURN();
}
| {
"code": [
"PPC_OP(btest_T1) ",
" regs->nip = T1 & ~3;",
" regs->nip = PARAM1;",
" RETURN();",
" } else {",
" } else {",
" } else {",
" } else {",
" } else {",
" } else {",
" } else {",
" } else {",
" RETURN();",
" ... | FUNC_0(VAR_0)
{
if (T0) {
regs->nip = T1 & ~3;
} else {
regs->nip = PARAM1;
}
RETURN();
}
| [
"FUNC_0(VAR_0)\n{",
"if (T0) {",
"regs->nip = T1 & ~3;",
"} else {",
"regs->nip = PARAM1;",
"}",
"RETURN();",
"}"
] | [
1,
0,
1,
0,
1,
0,
1,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
]
] |
10,802 | static BlockDriverState *bdrv_open_inherit(const char *filename,
const char *reference,
QDict *options, int flags,
BlockDriverState *parent,
con... | true | qemu | 180ca19ae02be70f9b158bfd7dec1ff123b9cf8c | static BlockDriverState *bdrv_open_inherit(const char *filename,
const char *reference,
QDict *options, int flags,
BlockDriverState *parent,
con... | {
"code": [
" if (bs->file != NULL) {",
" bdrv_unref_child(bs, bs->file);"
],
"line_no": [
457,
459
]
} | static BlockDriverState *FUNC_0(const char *filename,
const char *reference,
QDict *options, int flags,
BlockDriverState *parent,
const BdrvChil... | [
"static BlockDriverState *FUNC_0(const char *filename,\nconst char *reference,\nQDict *options, int flags,\nBlockDriverState *parent,\nconst BdrvChildRole *child_role,\nError **errp)\n{",
"int VAR_0;",
"BlockBackend *file = NULL;",
"BlockDriverState *bs;",
"BlockDriver *drv = NULL;",
"const char *VAR_1;",... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
35
],
[
37
],
[
41
],
[
43
],
[
45
],
[
49
],
[
51,
53
... |
10,804 | static void decode(Real288_internal *glob, float gain, int cb_coef)
{
unsigned int x, y;
float f;
double sum, sumsum;
float *p1, *p2;
float buffer[5];
for (x=36; x--; glob->sb[x+5] = glob->sb[x]);
for (x=5; x--;) {
p1 = glob->sb+x;
p2 = glob->pr1;
for (... | false | FFmpeg | 69c23e6f33c38ebc03ce7f51fcb963deaff7383b | static void decode(Real288_internal *glob, float gain, int cb_coef)
{
unsigned int x, y;
float f;
double sum, sumsum;
float *p1, *p2;
float buffer[5];
for (x=36; x--; glob->sb[x+5] = glob->sb[x]);
for (x=5; x--;) {
p1 = glob->sb+x;
p2 = glob->pr1;
for (... | {
"code": [],
"line_no": []
} | static void FUNC_0(Real288_internal *VAR_0, float VAR_1, int VAR_2)
{
unsigned int VAR_3, VAR_4;
float VAR_5;
double VAR_6, VAR_7;
float *VAR_8, *VAR_9;
float VAR_10[5];
for (VAR_3=36; VAR_3--; VAR_0->sb[VAR_3+5] = VAR_0->sb[VAR_3]);
for (VAR_3=5; VAR_3--;) {
VAR_8 = VAR... | [
"static void FUNC_0(Real288_internal *VAR_0, float VAR_1, int VAR_2)\n{",
"unsigned int VAR_3, VAR_4;",
"float VAR_5;",
"double VAR_6, VAR_7;",
"float *VAR_8, *VAR_9;",
"float VAR_10[5];",
"for (VAR_3=36; VAR_3--; VAR_0->sb[VAR_3+5] = VAR_0->sb[VAR_3]);",
"for (VAR_3=5; VAR_3--;) {",
"VAR_8 = VAR_0-... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
17
],
[
21
],
[
23
],
[
25
],
[
27
],
[
31
],
[
33
],
[
39
],
[
43,
45
],
[
47,
49
],
[
53
],
[
57
],
[
59
... |
10,805 | int url_open_dyn_packet_buf(AVIOContext **s, int max_packet_size)
{
if (max_packet_size <= 0)
return -1;
return url_open_dyn_buf_internal(s, max_packet_size);
}
| false | FFmpeg | 403ee835e7913eb9536b22c2b22edfdd700166a9 | int url_open_dyn_packet_buf(AVIOContext **s, int max_packet_size)
{
if (max_packet_size <= 0)
return -1;
return url_open_dyn_buf_internal(s, max_packet_size);
}
| {
"code": [],
"line_no": []
} | int FUNC_0(AVIOContext **VAR_0, int VAR_1)
{
if (VAR_1 <= 0)
return -1;
return url_open_dyn_buf_internal(VAR_0, VAR_1);
}
| [
"int FUNC_0(AVIOContext **VAR_0, int VAR_1)\n{",
"if (VAR_1 <= 0)\nreturn -1;",
"return url_open_dyn_buf_internal(VAR_0, VAR_1);",
"}"
] | [
0,
0,
0,
0
] | [
[
1,
3
],
[
5,
7
],
[
9
],
[
11
]
] |
10,806 | static int ffmal_update_format(AVCodecContext *avctx)
{
MMALDecodeContext *ctx = avctx->priv_data;
MMAL_STATUS_T status;
int ret = 0;
MMAL_COMPONENT_T *decoder = ctx->decoder;
MMAL_ES_FORMAT_T *format_out = decoder->output[0]->format;
ffmmal_poolref_unref(ctx->pool_out);
if (!(ctx-... | false | FFmpeg | d82d5379caca21005d8906829b35361c4a65408e | static int ffmal_update_format(AVCodecContext *avctx)
{
MMALDecodeContext *ctx = avctx->priv_data;
MMAL_STATUS_T status;
int ret = 0;
MMAL_COMPONENT_T *decoder = ctx->decoder;
MMAL_ES_FORMAT_T *format_out = decoder->output[0]->format;
ffmmal_poolref_unref(ctx->pool_out);
if (!(ctx-... | {
"code": [],
"line_no": []
} | static int FUNC_0(AVCodecContext *VAR_0)
{
MMALDecodeContext *ctx = VAR_0->priv_data;
MMAL_STATUS_T status;
int VAR_1 = 0;
MMAL_COMPONENT_T *decoder = ctx->decoder;
MMAL_ES_FORMAT_T *format_out = decoder->output[0]->format;
ffmmal_poolref_unref(ctx->pool_out);
if (!(ctx->pool_out =... | [
"static int FUNC_0(AVCodecContext *VAR_0)\n{",
"MMALDecodeContext *ctx = VAR_0->priv_data;",
"MMAL_STATUS_T status;",
"int VAR_1 = 0;",
"MMAL_COMPONENT_T *decoder = ctx->decoder;",
"MMAL_ES_FORMAT_T *format_out = decoder->output[0]->format;",
"ffmmal_poolref_unref(ctx->pool_out);",
"if (!(ctx->pool_ou... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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
],
[
31,
33
],
[
37,
39
],
[
43,
45
],
[
49
],
[
51
],
[
53
],
[... |
10,807 | static void gen_stswx(DisasContext *ctx)
{
TCGv t0;
TCGv_i32 t1, t2;
gen_set_access_type(ctx, ACCESS_INT);
/* NIP cannot be restored if the memory exception comes from an helper */
gen_update_nip(ctx, ctx->nip - 4);
t0 = tcg_temp_new();
gen_addr_reg_index(ctx, t0);
t1 = tcg_temp... | true | qemu | e41029b378b4a65a0b89b5a8dc087aca6b5d012d | static void gen_stswx(DisasContext *ctx)
{
TCGv t0;
TCGv_i32 t1, t2;
gen_set_access_type(ctx, ACCESS_INT);
gen_update_nip(ctx, ctx->nip - 4);
t0 = tcg_temp_new();
gen_addr_reg_index(ctx, t0);
t1 = tcg_temp_new_i32();
tcg_gen_trunc_tl_i32(t1, cpu_xer);
tcg_gen_andi_i32... | {
"code": [
" gen_update_nip(ctx, ctx->nip - 4);",
" gen_update_nip(ctx, ctx->nip - 4);",
" gen_update_nip(ctx, ctx->nip - 4);",
" gen_update_nip(ctx, ctx->nip - 4);"
],
"line_no": [
13,
13,
13,
13
]
} | static void FUNC_0(DisasContext *VAR_0)
{
TCGv t0;
TCGv_i32 t1, t2;
gen_set_access_type(VAR_0, ACCESS_INT);
gen_update_nip(VAR_0, VAR_0->nip - 4);
t0 = tcg_temp_new();
gen_addr_reg_index(VAR_0, t0);
t1 = tcg_temp_new_i32();
tcg_gen_trunc_tl_i32(t1, cpu_xer);
tcg_gen_a... | [
"static void FUNC_0(DisasContext *VAR_0)\n{",
"TCGv t0;",
"TCGv_i32 t1, t2;",
"gen_set_access_type(VAR_0, ACCESS_INT);",
"gen_update_nip(VAR_0, VAR_0->nip - 4);",
"t0 = tcg_temp_new();",
"gen_addr_reg_index(VAR_0, t0);",
"t1 = tcg_temp_new_i32();",
"tcg_gen_trunc_tl_i32(t1, cpu_xer);",
"tcg_gen_an... | [
0,
0,
0,
0,
1,
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
]
] |
10,808 | uint64_t HELPER(neon_abdl_s64)(uint32_t a, uint32_t b)
{
uint64_t result;
DO_ABD(result, a, b, int32_t);
return result;
}
| true | qemu | 4d9ad7f793605abd9806fc932b3e04e028894565 | uint64_t HELPER(neon_abdl_s64)(uint32_t a, uint32_t b)
{
uint64_t result;
DO_ABD(result, a, b, int32_t);
return result;
}
| {
"code": [
" DO_ABD(result, a, b, int32_t);"
],
"line_no": [
7
]
} | uint64_t FUNC_0(neon_abdl_s64)(uint32_t a, uint32_t b)
{
uint64_t result;
DO_ABD(result, a, b, int32_t);
return result;
}
| [
"uint64_t FUNC_0(neon_abdl_s64)(uint32_t a, uint32_t b)\n{",
"uint64_t result;",
"DO_ABD(result, a, b, int32_t);",
"return result;",
"}"
] | [
0,
0,
1,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
]
] |
10,809 | static int stdio_fclose(void *opaque)
{
QEMUFileStdio *s = opaque;
int ret = 0;
if (qemu_file_is_writable(s->file)) {
int fd = fileno(s->stdio_file);
struct stat st;
ret = fstat(fd, &st);
if (ret == 0 && S_ISREG(st.st_mode)) {
/*
* If th... | true | qemu | 60fe637bf0e4d7989e21e50f52526444765c63b4 | static int stdio_fclose(void *opaque)
{
QEMUFileStdio *s = opaque;
int ret = 0;
if (qemu_file_is_writable(s->file)) {
int fd = fileno(s->stdio_file);
struct stat st;
ret = fstat(fd, &st);
if (ret == 0 && S_ISREG(st.st_mode)) {
ret ... | {
"code": [],
"line_no": []
} | static int FUNC_0(void *VAR_0)
{
QEMUFileStdio *s = VAR_0;
int VAR_1 = 0;
if (qemu_file_is_writable(s->file)) {
int VAR_2 = fileno(s->stdio_file);
struct stat VAR_3;
VAR_1 = fstat(VAR_2, &VAR_3);
if (VAR_1 == 0 && S_ISREG(VAR_3.st_mode)) {
... | [
"static int FUNC_0(void *VAR_0)\n{",
"QEMUFileStdio *s = VAR_0;",
"int VAR_1 = 0;",
"if (qemu_file_is_writable(s->file)) {",
"int VAR_2 = fileno(s->stdio_file);",
"struct stat VAR_3;",
"VAR_1 = fstat(VAR_2, &VAR_3);",
"if (VAR_1 == 0 && S_ISREG(VAR_3.st_mode)) {",
"VAR_1 = fsync(VAR_2);",
"if (VAR... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
13
],
[
15
],
[
19
],
[
21
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49
],
[
51
],
[
53... |
10,810 | static hwaddr ppc_hash64_htab_lookup(CPUPPCState *env,
ppc_slb_t *slb, target_ulong eaddr,
ppc_hash_pte64_t *pte)
{
hwaddr pteg_off, pte_offset;
hwaddr hash;
uint64_t vsid, epnshift, epnmask, epn, ptem;
/* Page size accor... | true | qemu | f3c75d42adbba553eaf218a832d4fbea32c8f7b8 | static hwaddr ppc_hash64_htab_lookup(CPUPPCState *env,
ppc_slb_t *slb, target_ulong eaddr,
ppc_hash_pte64_t *pte)
{
hwaddr pteg_off, pte_offset;
hwaddr hash;
uint64_t vsid, epnshift, epnmask, epn, ptem;
epnshi... | {
"code": [
" pteg_off = (hash * HASH_PTEG_SIZE_64) & env->htab_mask;",
" pteg_off = (~hash * HASH_PTEG_SIZE_64) & env->htab_mask;"
],
"line_no": [
79,
99
]
} | static hwaddr FUNC_0(CPUPPCState *env,
ppc_slb_t *slb, target_ulong eaddr,
ppc_hash_pte64_t *pte)
{
hwaddr pteg_off, pte_offset;
hwaddr hash;
uint64_t vsid, epnshift, epnmask, epn, ptem;
epnshift = (slb->vsid ... | [
"static hwaddr FUNC_0(CPUPPCState *env,\nppc_slb_t *slb, target_ulong eaddr,\nppc_hash_pte64_t *pte)\n{",
"hwaddr pteg_off, pte_offset;",
"hwaddr hash;",
"uint64_t vsid, epnshift, epnmask, epn, ptem;",
"epnshift = (slb->vsid & SLB_VSID_L)\n? TARGET_PAGE_BITS_16M : TARGET_PAGE_BITS;",
"epnmask = ~((1ULL <<... | [
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
] | [
[
1,
3,
5,
7
],
[
9
],
[
11
],
[
13
],
[
25,
27
],
[
29
],
[
33
],
[
37
],
[
39
],
[
41
],
[
43
],
[
47
],
[
49
],
[
51
],
[
53
],
[
55
],
[
61,
63,
65
],
[... |
10,811 | static int dnxhd_init_qmat(DNXHDEncContext *ctx, int lbias, int cbias)
{
// init first elem to 1 to avoid div by 0 in convert_matrix
uint16_t weight_matrix[64] = {1,}; // convert_matrix needs uint16_t*
int qscale, i;
CHECKED_ALLOCZ(ctx->qmatrix_l, (ctx->m.avctx->qmax+1) * 64 * sizeof(int));
... | false | FFmpeg | d31dbec3742e488156621b9ca21069f8c05aabf0 | static int dnxhd_init_qmat(DNXHDEncContext *ctx, int lbias, int cbias)
{
uint16_t weight_matrix[64] = {1,};
int qscale, i;
CHECKED_ALLOCZ(ctx->qmatrix_l, (ctx->m.avctx->qmax+1) * 64 * sizeof(int));
CHECKED_ALLOCZ(ctx->qmatrix_c, (ctx->m.avctx->qmax+1) * 64 * sizeof(int));
CHECKED_... | {
"code": [],
"line_no": []
} | static int FUNC_0(DNXHDEncContext *VAR_0, int VAR_1, int VAR_2)
{
uint16_t weight_matrix[64] = {1,};
int VAR_3, VAR_4;
CHECKED_ALLOCZ(VAR_0->qmatrix_l, (VAR_0->m.avctx->qmax+1) * 64 * sizeof(int));
CHECKED_ALLOCZ(VAR_0->qmatrix_c, (VAR_0->m.avctx->qmax+1) * 64 * sizeof(int));
CHEC... | [
"static int FUNC_0(DNXHDEncContext *VAR_0, int VAR_1, int VAR_2)\n{",
"uint16_t weight_matrix[64] = {1,};",
"int VAR_3, VAR_4;",
"CHECKED_ALLOCZ(VAR_0->qmatrix_l, (VAR_0->m.avctx->qmax+1) * 64 * sizeof(int));",
"CHECKED_ALLOCZ(VAR_0->qmatrix_c, (VAR_0->m.avctx->qmax+1) * 64 * sizeof(int));",
"CHECKED_... | [
0,
0,
0,
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
],
[
7
],
[
9
],
[
13
],
[
15
],
[
17
],
[
19
],
[
23
],
[
25
],
[
27
],
[
29
],
[
31,
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43,
45
],
[
47
],
[
49... |
10,812 | static av_cold int a64multi_close_encoder(AVCodecContext *avctx)
{
A64Context *c = avctx->priv_data;
av_frame_free(&avctx->coded_frame);
av_free(c->mc_meta_charset);
av_free(c->mc_best_cb);
av_free(c->mc_charset);
av_free(c->mc_charmap);
av_free(c->mc_colram);
return 0;
}
| false | FFmpeg | d6604b29ef544793479d7fb4e05ef6622bb3e534 | static av_cold int a64multi_close_encoder(AVCodecContext *avctx)
{
A64Context *c = avctx->priv_data;
av_frame_free(&avctx->coded_frame);
av_free(c->mc_meta_charset);
av_free(c->mc_best_cb);
av_free(c->mc_charset);
av_free(c->mc_charmap);
av_free(c->mc_colram);
return 0;
}
| {
"code": [],
"line_no": []
} | static av_cold int FUNC_0(AVCodecContext *avctx)
{
A64Context *c = avctx->priv_data;
av_frame_free(&avctx->coded_frame);
av_free(c->mc_meta_charset);
av_free(c->mc_best_cb);
av_free(c->mc_charset);
av_free(c->mc_charmap);
av_free(c->mc_colram);
return 0;
}
| [
"static av_cold int FUNC_0(AVCodecContext *avctx)\n{",
"A64Context *c = avctx->priv_data;",
"av_frame_free(&avctx->coded_frame);",
"av_free(c->mc_meta_charset);",
"av_free(c->mc_best_cb);",
"av_free(c->mc_charset);",
"av_free(c->mc_charmap);",
"av_free(c->mc_colram);",
"return 0;",
"}"
] | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
]
] |
10,814 | void helper_stf_asi(target_ulong addr, int asi, int size, int rd)
{
unsigned int i;
target_ulong val = 0;
helper_check_align(addr, 3);
addr = asi_address_mask(env, asi, addr);
switch (asi) {
case 0xe0: // UA2007 Block commit store primary (cache flush)
case 0xe1: // UA2007 Block commit store... | true | qemu | 0e2fa9cab9c124788077de728f1e6744d1dd8bb2 | void helper_stf_asi(target_ulong addr, int asi, int size, int rd)
{
unsigned int i;
target_ulong val = 0;
helper_check_align(addr, 3);
addr = asi_address_mask(env, asi, addr);
switch (asi) {
case 0xe0:
case 0xe1:
case 0xf0:
case 0xf1:
case 0xf8: LE
case 0xf9: LE
... | {
"code": [],
"line_no": []
} | void FUNC_0(target_ulong VAR_0, int VAR_1, int VAR_2, int VAR_3)
{
unsigned int VAR_4;
target_ulong val = 0;
helper_check_align(VAR_0, 3);
VAR_0 = asi_address_mask(env, VAR_1, VAR_0);
switch (VAR_1) {
case 0xe0:
case 0xe1:
case 0xf0:
case 0xf1:
case 0xf8: LE
case 0xf9: ... | [
"void FUNC_0(target_ulong VAR_0, int VAR_1, int VAR_2, int VAR_3)\n{",
"unsigned int VAR_4;",
"target_ulong val = 0;",
"helper_check_align(VAR_0, 3);",
"VAR_0 = asi_address_mask(env, VAR_1, VAR_0);",
"switch (VAR_1) {",
"case 0xe0:\ncase 0xe1:\ncase 0xf0:\ncase 0xf1:\ncase 0xf8: LE\ncase 0xf9: LE\nhel... | [
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
],
[
24
],
[
25,
27
],
[
... |
10,816 | static int drive_add(const char *file, const char *fmt, ...)
{
va_list ap;
int index = drive_opt_get_free_idx();
if (nb_drives_opt >= MAX_DRIVES || index == -1) {
fprintf(stderr, "qemu: too many drives\n");
exit(1);
}
drives_opt[index].file = file;
va_start(ap, fmt);... | true | qemu | 4d73cd3b3f55fcff433ce64b125b7adb8aaece29 | static int drive_add(const char *file, const char *fmt, ...)
{
va_list ap;
int index = drive_opt_get_free_idx();
if (nb_drives_opt >= MAX_DRIVES || index == -1) {
fprintf(stderr, "qemu: too many drives\n");
exit(1);
}
drives_opt[index].file = file;
va_start(ap, fmt);... | {
"code": [
"static int drive_add(const char *file, const char *fmt, ...)",
" exit(1);"
],
"line_no": [
1,
15
]
} | static int FUNC_0(const char *VAR_0, const char *VAR_1, ...)
{
va_list ap;
int VAR_2 = drive_opt_get_free_idx();
if (nb_drives_opt >= MAX_DRIVES || VAR_2 == -1) {
fprintf(stderr, "qemu: too many drives\n");
exit(1);
}
drives_opt[VAR_2].VAR_0 = VAR_0;
va_start(ap, VAR... | [
"static int FUNC_0(const char *VAR_0, const char *VAR_1, ...)\n{",
"va_list ap;",
"int VAR_2 = drive_opt_get_free_idx();",
"if (nb_drives_opt >= MAX_DRIVES || VAR_2 == -1) {",
"fprintf(stderr, \"qemu: too many drives\\n\");",
"exit(1);",
"}",
"drives_opt[VAR_2].VAR_0 = VAR_0;",
"va_start(ap, VAR_1);... | [
1,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
11
],
[
13
],
[
15
],
[
17
],
[
21
],
[
23
],
[
25,
27
],
[
29
],
[
33
],
[
35
],
[
37
]
] |
10,817 | int avcodec_close(AVCodecContext *avctx)
{
entangled_thread_counter++;
if(entangled_thread_counter != 1){
av_log(avctx, AV_LOG_ERROR, "insufficient thread locking around avcodec_open/close()\n");
entangled_thread_counter--;
return -1;
}
if (ENABLE_THREADS && avctx->thre... | true | FFmpeg | ef2b64f04c7269fe59dab0491784e06ade7892ca | int avcodec_close(AVCodecContext *avctx)
{
entangled_thread_counter++;
if(entangled_thread_counter != 1){
av_log(avctx, AV_LOG_ERROR, "insufficient thread locking around avcodec_open/close()\n");
entangled_thread_counter--;
return -1;
}
if (ENABLE_THREADS && avctx->thre... | {
"code": [],
"line_no": []
} | int FUNC_0(AVCodecContext *VAR_0)
{
entangled_thread_counter++;
if(entangled_thread_counter != 1){
av_log(VAR_0, AV_LOG_ERROR, "insufficient thread locking around avcodec_open/close()\n");
entangled_thread_counter--;
return -1;
}
if (ENABLE_THREADS && VAR_0->thread_opaq... | [
"int FUNC_0(AVCodecContext *VAR_0)\n{",
"entangled_thread_counter++;",
"if(entangled_thread_counter != 1){",
"av_log(VAR_0, AV_LOG_ERROR, \"insufficient thread locking around avcodec_open/close()\\n\");",
"entangled_thread_counter--;",
"return -1;",
"}",
"if (ENABLE_THREADS && VAR_0->thread_opaque)\na... | [
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
],
[
32
],
[
34
],
[
36
],
[
38
]
] |
10,818 | void av_dump_format(AVFormatContext *ic, int index,
const char *url, int is_output)
{
int i;
uint8_t *printed = ic->nb_streams ? av_mallocz(ic->nb_streams) : NULL;
if (ic->nb_streams && !printed)
return;
av_log(NULL, AV_LOG_INFO, "%s #%d, %s, %s '%s':\n",
... | true | FFmpeg | 949444348b752664243681625f9f1d2c55b6dfaa | void av_dump_format(AVFormatContext *ic, int index,
const char *url, int is_output)
{
int i;
uint8_t *printed = ic->nb_streams ? av_mallocz(ic->nb_streams) : NULL;
if (ic->nb_streams && !printed)
return;
av_log(NULL, AV_LOG_INFO, "%s #%d, %s, %s '%s':\n",
... | {
"code": [
" secs = ic->start_time / AV_TIME_BASE;",
" av_log(NULL, AV_LOG_INFO, \"%d.%06d\",",
" secs, (int) av_rescale(us, 1000000, AV_TIME_BASE));"
],
"line_no": [
69,
73,
75
]
} | void FUNC_0(AVFormatContext *VAR_0, int VAR_1,
const char *VAR_2, int VAR_3)
{
int VAR_4;
uint8_t *printed = VAR_0->nb_streams ? av_mallocz(VAR_0->nb_streams) : NULL;
if (VAR_0->nb_streams && !printed)
return;
av_log(NULL, AV_LOG_INFO, "%s #%d, %s, %s '%s':\n",
... | [
"void FUNC_0(AVFormatContext *VAR_0, int VAR_1,\nconst char *VAR_2, int VAR_3)\n{",
"int VAR_4;",
"uint8_t *printed = VAR_0->nb_streams ? av_mallocz(VAR_0->nb_streams) : NULL;",
"if (VAR_0->nb_streams && !printed)\nreturn;",
"av_log(NULL, AV_LOG_INFO, \"%s #%d, %s, %s '%s':\\n\",\nVAR_3 ? \"Output\" : \"Inp... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
1,
0,
0,
0,
0,
0,
0,
0,
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
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
43
],
[
45
],
[
47
],
[
49
],
[
51
... |
10,819 | static void vp8_idct_add_c(uint8_t *dst, DCTELEM block[16], ptrdiff_t stride)
{
int i, t0, t1, t2, t3;
uint8_t *cm = ff_cropTbl + MAX_NEG_CROP;
DCTELEM tmp[16];
for (i = 0; i < 4; i++) {
t0 = block[0*4+i] + block[2*4+i];
t1 = block[0*4+i] - block[2*4+i];
t2 = MUL_35468(... | true | FFmpeg | c23acbaed40101c677dfcfbbfe0d2c230a8e8f44 | static void vp8_idct_add_c(uint8_t *dst, DCTELEM block[16], ptrdiff_t stride)
{
int i, t0, t1, t2, t3;
uint8_t *cm = ff_cropTbl + MAX_NEG_CROP;
DCTELEM tmp[16];
for (i = 0; i < 4; i++) {
t0 = block[0*4+i] + block[2*4+i];
t1 = block[0*4+i] - block[2*4+i];
t2 = MUL_35468(... | {
"code": [
" uint8_t *cm = ff_cropTbl + MAX_NEG_CROP;",
" uint8_t *cm = ff_cropTbl + MAX_NEG_CROP;",
" uint8_t *cm = ff_cropTbl + MAX_NEG_CROP;",
" uint8_t *cm = ff_cropTbl + MAX_NEG_CROP;",
" uint8_t *cm = ff_cropTbl + MAX_NEG_CROP;",
" uint8_t *cm = ff_cropTbl + MAX_NEG_CR... | static void FUNC_0(uint8_t *VAR_0, DCTELEM VAR_1[16], ptrdiff_t VAR_2)
{
int VAR_3, VAR_4, VAR_5, VAR_6, VAR_7;
uint8_t *cm = ff_cropTbl + MAX_NEG_CROP;
DCTELEM tmp[16];
for (VAR_3 = 0; VAR_3 < 4; VAR_3++) {
VAR_4 = VAR_1[0*4+VAR_3] + VAR_1[2*4+VAR_3];
VAR_5 = VAR_1[0*4+VAR_3] -... | [
"static void FUNC_0(uint8_t *VAR_0, DCTELEM VAR_1[16], ptrdiff_t VAR_2)\n{",
"int VAR_3, VAR_4, VAR_5, VAR_6, VAR_7;",
"uint8_t *cm = ff_cropTbl + MAX_NEG_CROP;",
"DCTELEM tmp[16];",
"for (VAR_3 = 0; VAR_3 < 4; VAR_3++) {",
"VAR_4 = VAR_1[0*4+VAR_3] + VAR_1[2*4+VAR_3];",
"VAR_5 = VAR_1[0*4+VAR_3] - VAR_... | [
0,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
1,
1,
1,
1,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
27
],
[
29
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41
],
[
45
],
[
47
... |
10,821 | static int get_next_block(DumpState *s, RAMBlock *block)
{
while (1) {
block = QTAILQ_NEXT(block, next);
if (!block) {
/* no more block */
return 1;
}
s->start = 0;
s->block = block;
if (s->has_filter) {
if (block->offs... | true | qemu | 56c4bfb3f07f3107894c00281276aea4f5e8834d | static int get_next_block(DumpState *s, RAMBlock *block)
{
while (1) {
block = QTAILQ_NEXT(block, next);
if (!block) {
return 1;
}
s->start = 0;
s->block = block;
if (s->has_filter) {
if (block->offset >= s->begin + s-... | {
"code": [
" if (block->offset >= s->begin + s->length ||",
" block->offset + block->length <= s->begin) {",
"static int get_next_block(DumpState *s, RAMBlock *block)",
" s->block = block;",
" if (block->offset >= s->begin + s->length ||",
" ... | static int FUNC_0(DumpState *VAR_0, RAMBlock *VAR_1)
{
while (1) {
VAR_1 = QTAILQ_NEXT(VAR_1, next);
if (!VAR_1) {
return 1;
}
VAR_0->start = 0;
VAR_0->VAR_1 = VAR_1;
if (VAR_0->has_filter) {
if (VAR_1->offset >= VAR_0... | [
"static int FUNC_0(DumpState *VAR_0, RAMBlock *VAR_1)\n{",
"while (1) {",
"VAR_1 = QTAILQ_NEXT(VAR_1, next);",
"if (!VAR_1) {",
"return 1;",
"}",
"VAR_0->start = 0;",
"VAR_0->VAR_1 = VAR_1;",
"if (VAR_0->has_filter) {",
"if (VAR_1->offset >= VAR_0->begin + VAR_0->length ||\nVAR_1->offset + VAR_1->... | [
1,
0,
0,
0,
0,
0,
0,
1,
0,
1,
0,
0,
1,
1,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
9
],
[
13
],
[
15
],
[
19
],
[
21
],
[
23
],
[
25,
27
],
[
31
],
[
33
],
[
37
],
[
39
],
[
41
],
[
43
],
[
47
],
[
49
],
[
51
]
] |
10,822 | static void scsi_req_xfer_mode(SCSIRequest *req)
{
switch (req->cmd.buf[0]) {
case WRITE_6:
case WRITE_10:
case WRITE_VERIFY:
case WRITE_12:
case WRITE_VERIFY_12:
case WRITE_16:
case WRITE_VERIFY_16:
case COPY:
case COPY_VERIFY:
case COMPARE:
case CHANGE_DEFI... | true | qemu | 5e30a07d6d70d3073ff61e6db79d61c2b688502f | static void scsi_req_xfer_mode(SCSIRequest *req)
{
switch (req->cmd.buf[0]) {
case WRITE_6:
case WRITE_10:
case WRITE_VERIFY:
case WRITE_12:
case WRITE_VERIFY_12:
case WRITE_16:
case WRITE_VERIFY_16:
case COPY:
case COPY_VERIFY:
case COMPARE:
case CHANGE_DEFI... | {
"code": [
" case WRITE_LONG:",
" case WRITE_SAME:",
" case WRITE_VERIFY:",
" case WRITE_VERIFY:",
" case WRITE_LONG:",
" case WRITE_SAME:",
" case WRITE_LONG_2:",
" case WRITE_VERIFY:"
],
"line_no": [
51,
53,
11,
11,
51,
53,
65,... | static void FUNC_0(SCSIRequest *VAR_0)
{
switch (VAR_0->cmd.buf[0]) {
case WRITE_6:
case WRITE_10:
case WRITE_VERIFY:
case WRITE_12:
case WRITE_VERIFY_12:
case WRITE_16:
case WRITE_VERIFY_16:
case COPY:
case COPY_VERIFY:
case COMPARE:
case CHANGE_DEFINITION:
... | [
"static void FUNC_0(SCSIRequest *VAR_0)\n{",
"switch (VAR_0->cmd.buf[0]) {",
"case WRITE_6:\ncase WRITE_10:\ncase WRITE_VERIFY:\ncase WRITE_12:\ncase WRITE_VERIFY_12:\ncase WRITE_16:\ncase WRITE_VERIFY_16:\ncase COPY:\ncase COPY_VERIFY:\ncase COMPARE:\ncase CHANGE_DEFINITION:\ncase LOG_SELECT:\ncase MODE_SELECT... | [
0,
0,
1,
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
],
[
73
... |
10,823 | static int decode_hextile(VmncContext *c, uint8_t *dst, const uint8_t *src,
int ssize, int w, int h, int stride)
{
int i, j, k;
int bg = 0, fg = 0, rects, color, flags, xy, wh;
const int bpp = c->bpp2;
uint8_t *dst2;
int bw = 16, bh = 16;
const uint8_t *ssrc = s... | true | FFmpeg | 61cd19b8bc32185c8caf64d89d1b0909877a0707 | static int decode_hextile(VmncContext *c, uint8_t *dst, const uint8_t *src,
int ssize, int w, int h, int stride)
{
int i, j, k;
int bg = 0, fg = 0, rects, color, flags, xy, wh;
const int bpp = c->bpp2;
uint8_t *dst2;
int bw = 16, bh = 16;
const uint8_t *ssrc = s... | {
"code": [
"static int decode_hextile(VmncContext *c, uint8_t *dst, const uint8_t *src,",
" int ssize, int w, int h, int stride)",
" const uint8_t *ssrc = src;",
" if (src - ssrc >= ssize) {",
" flags = *src++;",
" if (src - ssr... | static int FUNC_0(VmncContext *VAR_0, uint8_t *VAR_1, const uint8_t *VAR_2,
int VAR_3, int VAR_4, int VAR_5, int VAR_6)
{
int VAR_7, VAR_8, VAR_9;
int VAR_10 = 0, VAR_11 = 0, VAR_12, VAR_13, VAR_14, VAR_15, VAR_16;
const int VAR_17 = VAR_0->bpp2;
uint8_t *dst2;
int V... | [
"static int FUNC_0(VmncContext *VAR_0, uint8_t *VAR_1, const uint8_t *VAR_2,\nint VAR_3, int VAR_4, int VAR_5, int VAR_6)\n{",
"int VAR_7, VAR_8, VAR_9;",
"int VAR_10 = 0, VAR_11 = 0, VAR_12, VAR_13, VAR_14, VAR_15, VAR_16;",
"const int VAR_17 = VAR_0->bpp2;",
"uint8_t *dst2;",
"int VAR_18 = 16, VAR_19 = ... | [
1,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
0,
1,
0,
0,
0,
0,
1,
0,
1,
0,
0,
0,
1,
1,
0,
1,
1,
1,
0,
1,
1,
0,
0,
0,
1,
0,
0,
1,
0,
0,
0,
0,
1,
1,
1,
0,
1,
1,
1,
0,
0,
0,
0,
0,
1,
0
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
21
],
[
23
],
[
25
],
[
27,
29
],
[
31
],
[
33
],
[
35
],
[
37
],
[
39
],
[
41,
43
],
[
45
],
[... |
10,824 | void do_interrupt(CPUState *env)
{
int intno = env->exception_index;
#ifdef DEBUG_PCALL
if (qemu_loglevel_mask(CPU_LOG_INT)) {
static int count;
const char *name;
if (intno < 0 || intno >= 0x180)
name = "Unknown";
else if (intno >= 0x100)
nam... | true | qemu | 5210977a8511fc0c4a8a1a68c01fa3b65e29edc0 | void do_interrupt(CPUState *env)
{
int intno = env->exception_index;
#ifdef DEBUG_PCALL
if (qemu_loglevel_mask(CPU_LOG_INT)) {
static int count;
const char *name;
if (intno < 0 || intno >= 0x180)
name = "Unknown";
else if (intno >= 0x100)
nam... | {
"code": [
" if (!(env->def->features & CPU_FEATURE_GL)) {",
" switch (intno) {",
" case TT_IVEC:",
" change_pstate(PS_PEF | PS_PRIV | PS_IG);",
" break;",
" case TT_TFAULT:",
" case TT_TMISS:",
" case TT_DFAULT:",
" ... | void FUNC_0(CPUState *VAR_0)
{
int VAR_1 = VAR_0->exception_index;
#ifdef DEBUG_PCALL
if (qemu_loglevel_mask(CPU_LOG_INT)) {
static int count;
const char *name;
if (VAR_1 < 0 || VAR_1 >= 0x180)
name = "Unknown";
else if (VAR_1 >= 0x100)
name ... | [
"void FUNC_0(CPUState *VAR_0)\n{",
"int VAR_1 = VAR_0->exception_index;",
"#ifdef DEBUG_PCALL\nif (qemu_loglevel_mask(CPU_LOG_INT)) {",
"static int count;",
"const char *name;",
"if (VAR_1 < 0 || VAR_1 >= 0x180)\nname = \"Unknown\";",
"else if (VAR_1 >= 0x100)\nname = \"Trap Instruction\";",
"else 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,
1,
1,
1,
1,
1,
0,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1,
3
],
[
5
],
[
9,
11
],
[
13
],
[
15
],
[
19,
21
],
[
23,
25
],
[
27,
29
],
[
31,
33
],
[
35
],
[
37
],
[
39,
41
],
[
43
],
[
47,
49,
51,
53,
55
],
[
57... |
10,825 | int bdrv_open2(BlockDriverState *bs, const char *filename, int flags,
BlockDriver *drv)
{
int ret, open_flags;
char tmp_filename[PATH_MAX];
char backing_filename[PATH_MAX];
bs->read_only = 0;
bs->is_temporary = 0;
bs->encrypted = 0;
bs->autogrow = 0;
if (flag... | true | qemu | b5eff355460643d09e533024360fe0522f368c07 | int bdrv_open2(BlockDriverState *bs, const char *filename, int flags,
BlockDriver *drv)
{
int ret, open_flags;
char tmp_filename[PATH_MAX];
char backing_filename[PATH_MAX];
bs->read_only = 0;
bs->is_temporary = 0;
bs->encrypted = 0;
bs->autogrow = 0;
if (flag... | {
"code": [
" return 0;",
" return 0;",
" bs->autogrow = 0;",
" if (flags & BDRV_O_AUTOGROW)",
" bs->autogrow = 1;"
],
"line_no": [
211,
211,
21,
25,
27
]
} | int FUNC_0(BlockDriverState *VAR_0, const char *VAR_1, int VAR_2,
BlockDriver *VAR_3)
{
int VAR_4, VAR_5;
char VAR_6[PATH_MAX];
char VAR_7[PATH_MAX];
VAR_0->read_only = 0;
VAR_0->is_temporary = 0;
VAR_0->encrypted = 0;
VAR_0->autogrow = 0;
if (VAR_2 & BDRV_O_... | [
"int FUNC_0(BlockDriverState *VAR_0, const char *VAR_1, int VAR_2,\nBlockDriver *VAR_3)\n{",
"int VAR_4, VAR_5;",
"char VAR_6[PATH_MAX];",
"char VAR_7[PATH_MAX];",
"VAR_0->read_only = 0;",
"VAR_0->is_temporary = 0;",
"VAR_0->encrypted = 0;",
"VAR_0->autogrow = 0;",
"if (VAR_2 & BDRV_O_AUTOGROW)\nVAR... | [
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
15
],
[
17
],
[
19
],
[
21
],
[
25,
27
],
[
31
],
[
33
],
[
35
],
[
47
],
[
49
],
[
51
],
[
53
],
[
55
],
[
57
],
[
59
... |
10,826 | int ff_pre_estimate_p_frame_motion(MpegEncContext * s,
int mb_x, int mb_y)
{
MotionEstContext * const c= &s->me;
int mx, my, dmin;
int P[10][2];
const int shift= 1+s->quarter_sample;
const int xy= mb_x + mb_y*s->mb_stride;
init_ref(c, s->new_picture.f.... | true | FFmpeg | f6774f905fb3cfdc319523ac640be30b14c1bc55 | int ff_pre_estimate_p_frame_motion(MpegEncContext * s,
int mb_x, int mb_y)
{
MotionEstContext * const c= &s->me;
int mx, my, dmin;
int P[10][2];
const int shift= 1+s->quarter_sample;
const int xy= mb_x + mb_y*s->mb_stride;
init_ref(c, s->new_picture.f.... | {
"code": [
" init_ref(c, s->new_picture.f.data, s->last_picture.f.data, NULL, 16*mb_x, 16*mb_y, 0);",
" init_ref(c, s->new_picture.f.data, s->last_picture.f.data, NULL, 16*mb_x, 16*mb_y, 0);"
],
"line_no": [
17,
17
]
} | int FUNC_0(MpegEncContext * VAR_0,
int VAR_1, int VAR_2)
{
MotionEstContext * const c= &VAR_0->me;
int VAR_3, VAR_4, VAR_5;
int VAR_6[10][2];
const int VAR_7= 1+VAR_0->quarter_sample;
const int VAR_8= VAR_1 + VAR_2*VAR_0->mb_stride;
init_ref(c, VAR_0->... | [
"int FUNC_0(MpegEncContext * VAR_0,\nint VAR_1, int VAR_2)\n{",
"MotionEstContext * const c= &VAR_0->me;",
"int VAR_3, VAR_4, VAR_5;",
"int VAR_6[10][2];",
"const int VAR_7= 1+VAR_0->quarter_sample;",
"const int VAR_8= VAR_1 + VAR_2*VAR_0->mb_stride;",
"init_ref(c, VAR_0->new_picture.f.data, VAR_0->last... | [
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
] | [
[
1,
3,
5
],
[
7
],
[
9
],
[
11
],
[
13
],
[
15
],
[
17
],
[
21
],
[
25
],
[
27
],
[
31
],
[
33
],
[
37
],
[
39
],
[
43
],
[
49
],
[
51
],
[
53
],
[
55,
57
... |
10,827 | static inline int gsm_mult(int a, int b)
{
return (a * b + (1 << 14)) >> 15;
}
| true | FFmpeg | a59505ca76718549dfc51b9622e2d88cb60f33b5 | static inline int gsm_mult(int a, int b)
{
return (a * b + (1 << 14)) >> 15;
}
| {
"code": [
" return (a * b + (1 << 14)) >> 15;"
],
"line_no": [
5
]
} | static inline int FUNC_0(int VAR_0, int VAR_1)
{
return (VAR_0 * VAR_1 + (1 << 14)) >> 15;
}
| [
"static inline int FUNC_0(int VAR_0, int VAR_1)\n{",
"return (VAR_0 * VAR_1 + (1 << 14)) >> 15;",
"}"
] | [
0,
1,
0
] | [
[
1,
3
],
[
5
],
[
7
]
] |
10,829 | int ff_xvid_rate_control_init(MpegEncContext *s){
char *tmp_name;
int fd, i;
xvid_plg_create_t xvid_plg_create;
xvid_plugin_2pass2_t xvid_2pass2;
//xvid_debug=-1;
fd=av_tempfile("xvidrc.", &tmp_name, 0, s->avctx);
if (fd == -1) {
av_log(NULL, AV_LOG_ERROR, "Can't create tempo... | false | FFmpeg | 25f35df11583800ee296effd42c51c65e9f3ef72 | int ff_xvid_rate_control_init(MpegEncContext *s){
char *tmp_name;
int fd, i;
xvid_plg_create_t xvid_plg_create;
xvid_plugin_2pass2_t xvid_2pass2;
fd=av_tempfile("xvidrc.", &tmp_name, 0, s->avctx);
if (fd == -1) {
av_log(NULL, AV_LOG_ERROR, "Can't create temporary pass2 file.... | {
"code": [],
"line_no": []
} | int FUNC_0(MpegEncContext *VAR_0){
char *VAR_1;
int VAR_2, VAR_3;
xvid_plg_create_t xvid_plg_create;
xvid_plugin_2pass2_t xvid_2pass2;
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 pass2 file.\n")... | [
"int FUNC_0(MpegEncContext *VAR_0){",
"char *VAR_1;",
"int VAR_2, VAR_3;",
"xvid_plg_create_t xvid_plg_create;",
"xvid_plugin_2pass2_t xvid_2pass2;",
"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 pass2 file.\\n\")... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
] | [
[
1
],
[
3
],
[
5
],
[
7
],
[
9
],
[
17
],
[
19
],
[
21
],
[
23
],
[
25
],
[
29
],
[
31
],
[
33
],
[
35
],
[
39
],
[
43,
45,
47
],
[
53
],
[
55
],
[
59
],
[... |
10,830 | static int dct_quantize_c(MpegEncContext *s,
DCTELEM *block, int n,
int qscale)
{
int i, j, level, last_non_zero, q;
const int *qmat;
int minLevel, maxLevel;
if(s->avctx!=NULL && s->avctx->codec->id==CODEC_ID_MPEG4){
/* mpeg4 */
minLev... | true | FFmpeg | d7e9533aa06f4073a27812349b35ba5fede11ca1 | static int dct_quantize_c(MpegEncContext *s,
DCTELEM *block, int n,
int qscale)
{
int i, j, level, last_non_zero, q;
const int *qmat;
int minLevel, maxLevel;
if(s->avctx!=NULL && s->avctx->codec->id==CODEC_ID_MPEG4){
minLevel= -2048;
... | {
"code": [
" int minLevel, maxLevel;",
" if(s->avctx!=NULL && s->avctx->codec->id==CODEC_ID_MPEG4){",
" minLevel= -2048;",
"\tmaxLevel= 2047;",
" }else if(s->out_format==FMT_MPEG1){",
" minLevel= -255;",
"\tmaxLevel= 255;",
" }else if(s->out_format==FMT_MJPEG... | static int FUNC_0(MpegEncContext *VAR_0,
DCTELEM *VAR_1, int VAR_2,
int VAR_3)
{
int VAR_4, VAR_5, VAR_6, VAR_7, VAR_8;
const int *VAR_9;
int VAR_10, VAR_11;
if(VAR_0->avctx!=NULL && VAR_0->avctx->codec->id==CODEC_ID_MPEG4){
VAR_10= -... | [
"static int FUNC_0(MpegEncContext *VAR_0,\nDCTELEM *VAR_1, int VAR_2,\nint VAR_3)\n{",
"int VAR_4, VAR_5, VAR_6, VAR_7, VAR_8;",
"const int *VAR_9;",
"int VAR_10, VAR_11;",
"if(VAR_0->avctx!=NULL && VAR_0->avctx->codec->id==CODEC_ID_MPEG4){",
"VAR_10= -2048;",
"VAR_11= 2047;",
"}else if(VAR_0->out_for... | [
1,
0,
0,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
1,
0,
1,
1,
0,
1,
0,
0,
1,
0,
1,
0,
0,
0,
0,
0,
1,
1,
1,
1,
1,
1,
0,
1,
0,
1,
1,
1,
1,
1,
1,
1,
0,
0,
1,
1,
1,
1,
1,
0... | [
[
1,
3,
5,
7
],
[
9
],
[
11
],
[
13
],
[
17
],
[
21
],
[
23
],
[
25
],
[
29
],
[
31
],
[
33
],
[
37
],
[
39
],
[
41
],
[
45
],
[
47
],
[
49
],
[
53
],
[
61
... |
10,831 | static void drive_backup_abort(BlkActionState *common)
{
DriveBackupState *state = DO_UPCAST(DriveBackupState, common, common);
BlockDriverState *bs = state->bs;
/* Only cancel if it's the job we started */
if (bs && bs->job && bs->job == state->job) {
block_job_cancel_sync(bs->job);
... | true | qemu | 111049a4ecefc9cf1ac75c773f4c5c165f27fe63 | static void drive_backup_abort(BlkActionState *common)
{
DriveBackupState *state = DO_UPCAST(DriveBackupState, common, common);
BlockDriverState *bs = state->bs;
if (bs && bs->job && bs->job == state->job) {
block_job_cancel_sync(bs->job);
}
}
| {
"code": [
" BlockDriverState *bs = state->bs;",
" if (bs && bs->job && bs->job == state->job) {",
" block_job_cancel_sync(bs->job);",
" BlockDriverState *bs = state->bs;",
" if (bs && bs->job && bs->job == state->job) {",
" block_job_cancel_sync(bs->job);"
],
"l... | static void FUNC_0(BlkActionState *VAR_0)
{
DriveBackupState *state = DO_UPCAST(DriveBackupState, VAR_0, VAR_0);
BlockDriverState *bs = state->bs;
if (bs && bs->job && bs->job == state->job) {
block_job_cancel_sync(bs->job);
}
}
| [
"static void FUNC_0(BlkActionState *VAR_0)\n{",
"DriveBackupState *state = DO_UPCAST(DriveBackupState, VAR_0, VAR_0);",
"BlockDriverState *bs = state->bs;",
"if (bs && bs->job && bs->job == state->job) {",
"block_job_cancel_sync(bs->job);",
"}",
"}"
] | [
0,
0,
1,
1,
1,
0,
0
] | [
[
1,
3
],
[
5
],
[
7
],
[
13
],
[
15
],
[
17
],
[
19
]
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.