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
8,097
static inline int get_chroma_qp(int chroma_qp_index_offset, int qscale){ return chroma_qp[av_clip(qscale + chroma_qp_index_offset, 0, 51)]; }
true
FFmpeg
042ef4b720f5d3321d9b7eeeb2067c671d5aeefd
static inline int get_chroma_qp(int chroma_qp_index_offset, int qscale){ return chroma_qp[av_clip(qscale + chroma_qp_index_offset, 0, 51)]; }
{ "code": [ "static inline int get_chroma_qp(int chroma_qp_index_offset, int qscale){", " return chroma_qp[av_clip(qscale + chroma_qp_index_offset, 0, 51)];" ], "line_no": [ 1, 5 ] }
static inline int FUNC_0(int VAR_0, int VAR_1){ return chroma_qp[av_clip(VAR_1 + VAR_0, 0, 51)]; }
[ "static inline int FUNC_0(int VAR_0, int VAR_1){", "return chroma_qp[av_clip(VAR_1 + VAR_0, 0, 51)];", "}" ]
[ 1, 1, 0 ]
[ [ 1 ], [ 5 ], [ 7 ] ]
8,098
static int coroutine_fn iscsi_co_flush(BlockDriverState *bs) { IscsiLun *iscsilun = bs->opaque; struct IscsiTask iTask; if (bdrv_is_sg(bs)) { return 0; } if (!iscsilun->force_next_flush) { return 0; } iscsilun->force_next_flush = false; iscsi_co_init_iscs...
true
qemu
1b6bc94d5d43ff3e39abadae19f2dbcb0954eb93
static int coroutine_fn iscsi_co_flush(BlockDriverState *bs) { IscsiLun *iscsilun = bs->opaque; struct IscsiTask iTask; if (bdrv_is_sg(bs)) { return 0; } if (!iscsilun->force_next_flush) { return 0; } iscsilun->force_next_flush = false; iscsi_co_init_iscs...
{ "code": [ " if (bdrv_is_sg(bs)) {", " return 0;" ], "line_no": [ 11, 13 ] }
static int VAR_0 iscsi_co_flush(BlockDriverState *bs) { IscsiLun *iscsilun = bs->opaque; struct IscsiTask iTask; if (bdrv_is_sg(bs)) { return 0; } if (!iscsilun->force_next_flush) { return 0; } iscsilun->force_next_flush = false; iscsi_co_init_iscsitask(i...
[ "static int VAR_0 iscsi_co_flush(BlockDriverState *bs)\n{", "IscsiLun *iscsilun = bs->opaque;", "struct IscsiTask iTask;", "if (bdrv_is_sg(bs)) {", "return 0;", "}", "if (!iscsilun->force_next_flush) {", "return 0;", "}", "iscsilun->force_next_flush = false;", "iscsi_co_init_iscsitask(iscsilun, ...
[ 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 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 11 ], [ 13 ], [ 15 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 29 ], [ 31, 33, 35 ], [ 37 ], [ 39 ], [ 43 ], [ 45 ], [ 47 ], [ 49 ], [ 53...
8,099
static void mch_update_smram(MCHPCIState *mch) { PCIDevice *pd = PCI_DEVICE(mch); bool h_smrame = (pd->config[MCH_HOST_BRIDGE_ESMRAMC] & MCH_HOST_BRIDGE_ESMRAMC_H_SMRAME); uint32_t tseg_size; /* implement SMRAM.D_LCK */ if (pd->config[MCH_HOST_BRIDGE_SMRAM] & MCH_HOST_BRIDGE_SMRAM_D_LCK) { ...
true
qemu
2f295167e0c429cec233aef7dc8e9fd6f90376df
static void mch_update_smram(MCHPCIState *mch) { PCIDevice *pd = PCI_DEVICE(mch); bool h_smrame = (pd->config[MCH_HOST_BRIDGE_ESMRAMC] & MCH_HOST_BRIDGE_ESMRAMC_H_SMRAME); uint32_t tseg_size; if (pd->config[MCH_HOST_BRIDGE_SMRAM] & MCH_HOST_BRIDGE_SMRAM_D_LCK) { pd->config[MCH_HOST...
{ "code": [ " tseg_size = 0;" ], "line_no": [ 95 ] }
static void FUNC_0(MCHPCIState *VAR_0) { PCIDevice *pd = PCI_DEVICE(VAR_0); bool h_smrame = (pd->config[MCH_HOST_BRIDGE_ESMRAMC] & MCH_HOST_BRIDGE_ESMRAMC_H_SMRAME); uint32_t tseg_size; if (pd->config[MCH_HOST_BRIDGE_SMRAM] & MCH_HOST_BRIDGE_SMRAM_D_LCK) { pd->config[MCH_HOST_BRIDG...
[ "static void FUNC_0(MCHPCIState *VAR_0)\n{", "PCIDevice *pd = PCI_DEVICE(VAR_0);", "bool h_smrame = (pd->config[MCH_HOST_BRIDGE_ESMRAMC] & MCH_HOST_BRIDGE_ESMRAMC_H_SMRAME);", "uint32_t tseg_size;", "if (pd->config[MCH_HOST_BRIDGE_SMRAM] & MCH_HOST_BRIDGE_SMRAM_D_LCK) {", "pd->config[MCH_HOST_BRIDGE_SMRAM...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 27 ], [ 31 ], [ 35 ], [ 39 ], [ 41 ], [ 45 ], [ 47 ], [ 49 ], [ 53 ], [ 55 ], [ 57 ...
8,100
int ff_mjpeg_decode_sos(MJpegDecodeContext *s, const uint8_t *mb_bitmask, int mb_bitmask_size, const AVFrame *reference) { int len, nb_components, i, h, v, predictor, point_transform; int index, id, ret; const int block_size = s->lossless ? 1 : 8; int ilv, prev_shift; if (!s-...
true
FFmpeg
4705edbbb96e193f51c72248f508ae5693702a48
int ff_mjpeg_decode_sos(MJpegDecodeContext *s, const uint8_t *mb_bitmask, int mb_bitmask_size, const AVFrame *reference) { int len, nb_components, i, h, v, predictor, point_transform; int index, id, ret; const int block_size = s->lossless ? 1 : 8; int ilv, prev_shift; if (!s-...
{ "code": [], "line_no": [] }
int FUNC_0(MJpegDecodeContext *VAR_0, const uint8_t *VAR_1, int VAR_2, const AVFrame *VAR_3) { int VAR_4, VAR_5, VAR_6, VAR_7, VAR_8, VAR_9, VAR_10; int VAR_11, VAR_12, VAR_13; const int VAR_14 = VAR_0->lossless ? 1 : 8; int VAR_15, VAR_16; if (!VAR_0->got_picture) { ...
[ "int FUNC_0(MJpegDecodeContext *VAR_0, const uint8_t *VAR_1,\nint VAR_2, const AVFrame *VAR_3)\n{", "int VAR_4, VAR_5, VAR_6, VAR_7, VAR_8, VAR_9, VAR_10;", "int VAR_11, VAR_12, VAR_13;", "const int VAR_14 = VAR_0->lossless ? 1 : 8;", "int VAR_15, VAR_16;", "if (!VAR_0->got_picture) {", "av_log(VAR_0->a...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ [ 1, 2, 3 ], [ 4 ], [ 5 ], [ 6 ], [ 7 ], [ 8 ], [ 9, 10 ], [ 11 ], [ 12 ], [ 14 ], [ 15 ], [ 16 ], [ 17, 18, 19 ], [ 20 ], [ 21 ], [ 22 ], [ 23 ], [ 24 ],...
8,101
static void gen_rot_rm_im(DisasContext *s, int ot, int op1, int op2, int is_right) { int mask = (ot == OT_QUAD ? 0x3f : 0x1f); int shift; /* load */ if (op1 == OR_TMP0) { gen_op_ld_T0_A0(ot + s->mem_index); } else { gen_op_mov_TN_reg(ot, 0, op1); ...
true
qemu
38ebb396c955ceb2ef7e246248ceb7f8bfe1b774
static void gen_rot_rm_im(DisasContext *s, int ot, int op1, int op2, int is_right) { int mask = (ot == OT_QUAD ? 0x3f : 0x1f); int shift; if (op1 == OR_TMP0) { gen_op_ld_T0_A0(ot + s->mem_index); } else { gen_op_mov_TN_reg(ot, 0, op1); } ...
{ "code": [], "line_no": [] }
static void FUNC_0(DisasContext *VAR_0, int VAR_1, int VAR_2, int VAR_3, int VAR_4) { int VAR_5 = (VAR_1 == OT_QUAD ? 0x3f : 0x1f); int VAR_6; if (VAR_2 == OR_TMP0) { gen_op_ld_T0_A0(VAR_1 + VAR_0->mem_index); } else { gen_op_mov_TN_reg(VAR_1, 0,...
[ "static void FUNC_0(DisasContext *VAR_0, int VAR_1, int VAR_2, int VAR_3,\nint VAR_4)\n{", "int VAR_5 = (VAR_1 == OT_QUAD ? 0x3f : 0x1f);", "int VAR_6;", "if (VAR_2 == OR_TMP0) {", "gen_op_ld_T0_A0(VAR_1 + VAR_0->mem_index);", "} else {", "gen_op_mov_TN_reg(VAR_1, 0, VAR_2);", "}", "VAR_3 &= VAR_5;"...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5 ], [ 7 ], [ 9 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 27 ], [ 29 ], [ 31 ], [ 33, 35, 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ], [ 49 ], [...
8,102
void do_savevm(const char *name) { BlockDriverState *bs, *bs1; QEMUSnapshotInfo sn1, *sn = &sn1, old_sn1, *old_sn = &old_sn1; int must_delete, ret, i; BlockDriverInfo bdi1, *bdi = &bdi1; QEMUFile *f; int saved_vm_running; #ifdef _WIN32 struct _timeb tb; #else struct timeval tv...
true
qemu
2d22b18f77ab0a488762e9216575b8582f1adb7d
void do_savevm(const char *name) { BlockDriverState *bs, *bs1; QEMUSnapshotInfo sn1, *sn = &sn1, old_sn1, *old_sn = &old_sn1; int must_delete, ret, i; BlockDriverInfo bdi1, *bdi = &bdi1; QEMUFile *f; int saved_vm_running; #ifdef _WIN32 struct _timeb tb; #else struct timeval tv...
{ "code": [ " sn->vm_state_size = qemu_ftell(f);" ], "line_no": [ 135 ] }
void FUNC_0(const char *VAR_0) { BlockDriverState *bs, *bs1; QEMUSnapshotInfo sn1, *sn = &sn1, old_sn1, *old_sn = &old_sn1; int VAR_1, VAR_2, VAR_3; BlockDriverInfo bdi1, *bdi = &bdi1; QEMUFile *f; int VAR_4; #ifdef _WIN32 struct _timeb tb; #else struct timeval VAR_5; #endif ...
[ "void FUNC_0(const char *VAR_0)\n{", "BlockDriverState *bs, *bs1;", "QEMUSnapshotInfo sn1, *sn = &sn1, old_sn1, *old_sn = &old_sn1;", "int VAR_1, VAR_2, VAR_3;", "BlockDriverInfo bdi1, *bdi = &bdi1;", "QEMUFile *f;", "int VAR_4;", "#ifdef _WIN32\nstruct _timeb tb;", "#else\nstruct timeval VAR_5;", ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17, 19 ], [ 21, 23 ], [ 25, 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 43 ], [ 47 ], [ 49 ], [ 53 ], [...
8,104
static void co_sleep_cb(void *opaque) { CoSleepCB *sleep_cb = opaque; aio_co_wake(sleep_cb->co); }
true
qemu
6133b39f3c36623425a6ede9e89d93175fde15cd
static void co_sleep_cb(void *opaque) { CoSleepCB *sleep_cb = opaque; aio_co_wake(sleep_cb->co); }
{ "code": [], "line_no": [] }
static void FUNC_0(void *VAR_0) { CoSleepCB *sleep_cb = VAR_0; aio_co_wake(sleep_cb->co); }
[ "static void FUNC_0(void *VAR_0)\n{", "CoSleepCB *sleep_cb = VAR_0;", "aio_co_wake(sleep_cb->co);", "}" ]
[ 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 11 ], [ 13 ] ]
8,106
static int stellaris_enet_init(SysBusDevice *sbd) { DeviceState *dev = DEVICE(sbd); stellaris_enet_state *s = STELLARIS_ENET(dev); memory_region_init_io(&s->mmio, OBJECT(s), &stellaris_enet_ops, s, "stellaris_enet", 0x1000); sysbus_init_mmio(sbd, &s->mmio); sysbus_...
true
qemu
2e1198672759eda6e122ff38fcf6df06f27e0fe2
static int stellaris_enet_init(SysBusDevice *sbd) { DeviceState *dev = DEVICE(sbd); stellaris_enet_state *s = STELLARIS_ENET(dev); memory_region_init_io(&s->mmio, OBJECT(s), &stellaris_enet_ops, s, "stellaris_enet", 0x1000); sysbus_init_mmio(sbd, &s->mmio); sysbus_...
{ "code": [ " return 0;", " register_savevm(dev, \"stellaris_enet\", -1, 1,", " stellaris_enet_save, stellaris_enet_load, s);" ], "line_no": [ 37, 33, 35 ] }
static int FUNC_0(SysBusDevice *VAR_0) { DeviceState *dev = DEVICE(VAR_0); stellaris_enet_state *s = STELLARIS_ENET(dev); memory_region_init_io(&s->mmio, OBJECT(s), &stellaris_enet_ops, s, "stellaris_enet", 0x1000); sysbus_init_mmio(VAR_0, &s->mmio); sysbus_init_ir...
[ "static int FUNC_0(SysBusDevice *VAR_0)\n{", "DeviceState *dev = DEVICE(VAR_0);", "stellaris_enet_state *s = STELLARIS_ENET(dev);", "memory_region_init_io(&s->mmio, OBJECT(s), &stellaris_enet_ops, s,\n\"stellaris_enet\", 0x1000);", "sysbus_init_mmio(VAR_0, &s->mmio);", "sysbus_init_irq(VAR_0, &s->irq);", ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 11, 13 ], [ 15 ], [ 17 ], [ 19 ], [ 23, 25 ], [ 27 ], [ 31 ], [ 33, 35 ], [ 37 ], [ 39 ] ]
8,107
static int tcp_chr_new_client(CharDriverState *chr, QIOChannelSocket *sioc) { TCPCharDriver *s = chr->opaque; if (s->ioc != NULL) { return -1; } s->ioc = QIO_CHANNEL(sioc); object_ref(OBJECT(sioc)); if (s->do_nodelay) { qio_channel_set_delay(s->ioc, false); } if (...
true
qemu
a8fb542705ac7e0dcf00908bc47bf49cdd058abe
static int tcp_chr_new_client(CharDriverState *chr, QIOChannelSocket *sioc) { TCPCharDriver *s = chr->opaque; if (s->ioc != NULL) { return -1; } s->ioc = QIO_CHANNEL(sioc); object_ref(OBJECT(sioc)); if (s->do_nodelay) { qio_channel_set_delay(s->ioc, false); } if (...
{ "code": [ " if (s->do_telnetopt) {", " tcp_chr_telnet_init(chr);", " tcp_chr_connect(chr);" ], "line_no": [ 37, 39, 43 ] }
static int FUNC_0(CharDriverState *VAR_0, QIOChannelSocket *VAR_1) { TCPCharDriver *s = VAR_0->opaque; if (s->ioc != NULL) { return -1; } s->ioc = QIO_CHANNEL(VAR_1); object_ref(OBJECT(VAR_1)); if (s->do_nodelay) { qio_channel_set_delay(s->ioc, false); } if (s->li...
[ "static int FUNC_0(CharDriverState *VAR_0, QIOChannelSocket *VAR_1)\n{", "TCPCharDriver *s = VAR_0->opaque;", "if (s->ioc != NULL) {", "return -1;", "}", "s->ioc = QIO_CHANNEL(VAR_1);", "object_ref(OBJECT(VAR_1));", "if (s->do_nodelay) {", "qio_channel_set_delay(s->ioc, false);", "}", "if (s->li...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 1, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 15 ], [ 17 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [ 49 ...
8,108
static int raw_read_packet(AVFormatContext *s, AVPacket *pkt) { int ret, size, bps; // AVStream *st = s->streams[0]; size= RAW_SAMPLES*s->streams[0]->codec->block_align; ret= av_get_packet(s->pb, pkt, size); pkt->stream_index = 0; if (ret < 0) return ret; bps= av...
true
FFmpeg
7effbee66cf457c62f795d9b9ed3a1110b364b89
static int raw_read_packet(AVFormatContext *s, AVPacket *pkt) { int ret, size, bps; size= RAW_SAMPLES*s->streams[0]->codec->block_align; ret= av_get_packet(s->pb, pkt, size); pkt->stream_index = 0; if (ret < 0) return ret; bps= av_get_bits_per_sample(s->streams[0]-...
{ "code": [], "line_no": [] }
static int FUNC_0(AVFormatContext *VAR_0, AVPacket *VAR_1) { int VAR_2, VAR_3, VAR_4; VAR_3= RAW_SAMPLES*VAR_0->streams[0]->codec->block_align; VAR_2= av_get_packet(VAR_0->pb, VAR_1, VAR_3); VAR_1->stream_index = 0; if (VAR_2 < 0) return VAR_2; VAR_4= av_get_bits_p...
[ "static int FUNC_0(AVFormatContext *VAR_0, AVPacket *VAR_1)\n{", "int VAR_2, VAR_3, VAR_4;", "VAR_3= RAW_SAMPLES*VAR_0->streams[0]->codec->block_align;", "VAR_2= av_get_packet(VAR_0->pb, VAR_1, VAR_3);", "VAR_1->stream_index = 0;", "if (VAR_2 < 0)\nreturn VAR_2;", "VAR_4= av_get_bits_per_sample(VAR_0->s...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 11 ], [ 15 ], [ 20 ], [ 22, 24 ], [ 28 ], [ 30 ], [ 32, 34 ], [ 38 ], [ 40 ] ]
8,109
static int vdpau_hevc_start_frame(AVCodecContext *avctx, const uint8_t *buffer, uint32_t size) { HEVCContext *h = avctx->priv_data; HEVCFrame *pic = h->ref; struct vdpau_picture_context *pic_ctx = pic->hwaccel_picture_private; VdpPictureInfoHEVC *info = &pic_ctx...
true
FFmpeg
4e6d1c1f4ec83000a067ff14452b34c1f2d2a43a
static int vdpau_hevc_start_frame(AVCodecContext *avctx, const uint8_t *buffer, uint32_t size) { HEVCContext *h = avctx->priv_data; HEVCFrame *pic = h->ref; struct vdpau_picture_context *pic_ctx = pic->hwaccel_picture_private; VdpPictureInfoHEVC *info = &pic_ctx...
{ "code": [ " if (j > 16) {" ], "line_no": [ 413 ] }
static int FUNC_0(AVCodecContext *VAR_0, const uint8_t *VAR_1, uint32_t VAR_2) { HEVCContext *h = VAR_0->priv_data; HEVCFrame *pic = h->ref; struct vdpau_picture_context *VAR_3 = pic->hwaccel_picture_private; VdpPictureInfoHEVC *info = &VAR_3->info.hevc; ...
[ "static int FUNC_0(AVCodecContext *VAR_0,\nconst uint8_t *VAR_1, uint32_t VAR_2)\n{", "HEVCContext *h = VAR_0->priv_data;", "HEVCFrame *pic = h->ref;", "struct vdpau_picture_context *VAR_3 = pic->hwaccel_picture_private;", "VdpPictureInfoHEVC *info = &VAR_3->info.hevc;", "const HEVCSPS *VAR_4 = h->ps.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...
[ [ 1, 3, 5 ], [ 7 ], [ 9 ], [ 11 ], [ 15 ], [ 19 ], [ 21 ], [ 23 ], [ 25, 27 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ], [ 49 ], [ 55 ], [ 57 ], [ 59 ...
8,110
void usb_cancel_packet(USBPacket * p) { assert(p->owner != NULL); usb_device_cancel_packet(p->owner->dev, p); p->owner = NULL; }
true
qemu
f53c398aa603cea135ee58fd15249aeff7b9c7ea
void usb_cancel_packet(USBPacket * p) { assert(p->owner != NULL); usb_device_cancel_packet(p->owner->dev, p); p->owner = NULL; }
{ "code": [ " assert(p->owner != NULL);", " p->owner = NULL;", " assert(p->owner != NULL);", " usb_device_cancel_packet(p->owner->dev, p);", " p->owner = NULL;" ], "line_no": [ 5, 9, 5, 7, 9 ] }
void FUNC_0(USBPacket * VAR_0) { assert(VAR_0->owner != NULL); usb_device_cancel_packet(VAR_0->owner->dev, VAR_0); VAR_0->owner = NULL; }
[ "void FUNC_0(USBPacket * VAR_0)\n{", "assert(VAR_0->owner != NULL);", "usb_device_cancel_packet(VAR_0->owner->dev, VAR_0);", "VAR_0->owner = NULL;", "}" ]
[ 0, 1, 1, 1, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ] ]
8,113
static int cmp_func_names(const char *a, const char *b) { int ascii_diff, digit_diff; for (; !(ascii_diff = *a - *b) && *a; a++, b++); for (; av_isdigit(*a) && av_isdigit(*b); a++, b++); return (digit_diff = av_isdigit(*a) - av_isdigit(*b)) ? digit_diff : ascii_diff; }
false
FFmpeg
8bb376cf6b4ab8645daedb8becaa7163656436a4
static int cmp_func_names(const char *a, const char *b) { int ascii_diff, digit_diff; for (; !(ascii_diff = *a - *b) && *a; a++, b++); for (; av_isdigit(*a) && av_isdigit(*b); a++, b++); return (digit_diff = av_isdigit(*a) - av_isdigit(*b)) ? digit_diff : ascii_diff; }
{ "code": [], "line_no": [] }
static int FUNC_0(const char *VAR_0, const char *VAR_1) { int VAR_2, VAR_3; for (; !(VAR_2 = *VAR_0 - *VAR_1) && *VAR_0; VAR_0++, VAR_1++); for (; av_isdigit(*VAR_0) && av_isdigit(*VAR_1); VAR_0++, VAR_1++); return (VAR_3 = av_isdigit(*VAR_0) - av_isdigit(*VAR_1)) ? VAR_3 : VAR_2; }
[ "static int FUNC_0(const char *VAR_0, const char *VAR_1)\n{", "int VAR_2, VAR_3;", "for (; !(VAR_2 = *VAR_0 - *VAR_1) && *VAR_0; VAR_0++, VAR_1++);", "for (; av_isdigit(*VAR_0) && av_isdigit(*VAR_1); VAR_0++, VAR_1++);", "return (VAR_3 = av_isdigit(*VAR_0) - av_isdigit(*VAR_1)) ? VAR_3 : VAR_2;", "}" ]
[ 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 9 ], [ 11 ], [ 15 ], [ 17 ] ]
8,114
vu_queue_fill(VuDev *dev, VuVirtq *vq, const VuVirtqElement *elem, unsigned int len, unsigned int idx) { struct vring_used_elem uelem; if (unlikely(dev->broken)) { return; } vu_log_queue_fill(dev, vq, elem, len); idx = (idx + vq->used_idx) % vq->vri...
true
qemu
640601c7cb1b6b41d3e1a435b986266c2b71e9bc
vu_queue_fill(VuDev *dev, VuVirtq *vq, const VuVirtqElement *elem, unsigned int len, unsigned int idx) { struct vring_used_elem uelem; if (unlikely(dev->broken)) { return; } vu_log_queue_fill(dev, vq, elem, len); idx = (idx + vq->used_idx) % vq->vri...
{ "code": [ " if (unlikely(dev->broken)) {", " if (unlikely(dev->broken)) {", " if (unlikely(dev->broken)) {", " if (unlikely(dev->broken)) {" ], "line_no": [ 13, 13, 13, 13 ] }
FUNC_0(VuDev *VAR_0, VuVirtq *VAR_1, const VuVirtqElement *VAR_2, unsigned int VAR_3, unsigned int VAR_4) { struct vring_used_elem VAR_5; if (unlikely(VAR_0->broken)) { return; } vu_log_queue_fill(VAR_0, VAR_1, VAR_2, VAR_3); VAR_4 = (VAR_4 + VAR_1-...
[ "FUNC_0(VuDev *VAR_0, VuVirtq *VAR_1,\nconst VuVirtqElement *VAR_2,\nunsigned int VAR_3, unsigned int VAR_4)\n{", "struct vring_used_elem VAR_5;", "if (unlikely(VAR_0->broken)) {", "return;", "}", "vu_log_queue_fill(VAR_0, VAR_1, VAR_2, VAR_3);", "VAR_4 = (VAR_4 + VAR_1->used_idx) % VAR_1->vring.num;", ...
[ 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5, 7 ], [ 9 ], [ 13 ], [ 15 ], [ 17 ], [ 21 ], [ 25 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ] ]
8,115
void kvm_physical_sync_dirty_bitmap(target_phys_addr_t start_addr, target_phys_addr_t end_addr) { KVMState *s = kvm_state; KVMDirtyLog d; KVMSlot *mem = kvm_lookup_slot(s, start_addr); unsigned long alloc_size; ram_addr_t addr; target_phys_addr_t phys_addr = start_addr; dprintf("sy...
true
qemu
d3f8d37fe2d0c24ec8bac9c94d5b0e2dc09c0d2a
void kvm_physical_sync_dirty_bitmap(target_phys_addr_t start_addr, target_phys_addr_t end_addr) { KVMState *s = kvm_state; KVMDirtyLog d; KVMSlot *mem = kvm_lookup_slot(s, start_addr); unsigned long alloc_size; ram_addr_t addr; target_phys_addr_t phys_addr = start_addr; dprintf("sy...
{ "code": [ "void kvm_physical_sync_dirty_bitmap(target_phys_addr_t start_addr, target_phys_addr_t end_addr)", " KVMSlot *mem = kvm_lookup_slot(s, start_addr);", " dprintf(\"sync addr: %llx into %lx\\n\", start_addr, mem->phys_offset);", " fprintf(stderr, \"BUG: %s: invalid parameters...
void FUNC_0(target_phys_addr_t VAR_0, target_phys_addr_t VAR_1) { KVMState *s = kvm_state; KVMDirtyLog d; KVMSlot *mem = kvm_lookup_slot(s, VAR_0); unsigned long VAR_2; ram_addr_t addr; target_phys_addr_t phys_addr = VAR_0; dprintf("sync addr: %llx into %lx\n", VAR_0, mem->phys_off...
[ "void FUNC_0(target_phys_addr_t VAR_0, target_phys_addr_t VAR_1)\n{", "KVMState *s = kvm_state;", "KVMDirtyLog d;", "KVMSlot *mem = kvm_lookup_slot(s, VAR_0);", "unsigned long VAR_2;", "ram_addr_t addr;", "target_phys_addr_t phys_addr = VAR_0;", "dprintf(\"sync addr: %llx into %lx\\n\", VAR_0, mem->ph...
[ 1, 0, 0, 1, 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 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 31 ], [ 33 ], [ 37 ], [ 39, 41 ], [ 45 ], [ 47 ], [ 49 ], [...
8,116
static void gen_mullwo(DisasContext *ctx) { TCGv_i32 t0 = tcg_temp_new_i32(); TCGv_i32 t1 = tcg_temp_new_i32(); tcg_gen_trunc_tl_i32(t0, cpu_gpr[rA(ctx->opcode)]); tcg_gen_trunc_tl_i32(t1, cpu_gpr[rB(ctx->opcode)]); tcg_gen_muls2_i32(t0, t1, t0, t1); #if defined(TARGET_PPC64) tcg_gen_c...
true
qemu
61aa9a697a1ec9b102e86cb7ea96876e6f20afe3
static void gen_mullwo(DisasContext *ctx) { TCGv_i32 t0 = tcg_temp_new_i32(); TCGv_i32 t1 = tcg_temp_new_i32(); tcg_gen_trunc_tl_i32(t0, cpu_gpr[rA(ctx->opcode)]); tcg_gen_trunc_tl_i32(t1, cpu_gpr[rB(ctx->opcode)]); tcg_gen_muls2_i32(t0, t1, t0, t1); #if defined(TARGET_PPC64) tcg_gen_c...
{ "code": [], "line_no": [] }
static void FUNC_0(DisasContext *VAR_0) { TCGv_i32 t0 = tcg_temp_new_i32(); TCGv_i32 t1 = tcg_temp_new_i32(); tcg_gen_trunc_tl_i32(t0, cpu_gpr[rA(VAR_0->opcode)]); tcg_gen_trunc_tl_i32(t1, cpu_gpr[rB(VAR_0->opcode)]); tcg_gen_muls2_i32(t0, t1, t0, t1); #if defined(TARGET_PPC64) tcg_gen...
[ "static void FUNC_0(DisasContext *VAR_0)\n{", "TCGv_i32 t0 = tcg_temp_new_i32();", "TCGv_i32 t1 = tcg_temp_new_i32();", "tcg_gen_trunc_tl_i32(t0, cpu_gpr[rA(VAR_0->opcode)]);", "tcg_gen_trunc_tl_i32(t1, cpu_gpr[rB(VAR_0->opcode)]);", "tcg_gen_muls2_i32(t0, t1, t0, t1);", "#if defined(TARGET_PPC64)\ntcg_...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 11 ], [ 13 ], [ 15 ], [ 17, 19 ], [ 21, 23 ], [ 25, 29 ], [ 31 ], [ 33 ], [ 38 ], [ 42 ], [ 44 ], [ 46, 48 ] ]
8,117
static int http_parse_request(HTTPContext *c) { char *p; int post; char cmd[32]; char info[1024], *filename; char url[1024], *q; char protocol[32]; char msg[1024]; const char *mime_type; FFStream *stream; p = c->buffer; q = cmd; while (!isspace(*p) && *p !=...
true
FFmpeg
7434ba6d53b9a8858a6f965d9a4e60b5eb1316fe
static int http_parse_request(HTTPContext *c) { char *p; int post; char cmd[32]; char info[1024], *filename; char url[1024], *q; char protocol[32]; char msg[1024]; const char *mime_type; FFStream *stream; p = c->buffer; q = cmd; while (!isspace(*p) && *p !=...
{ "code": [ " strcpy(info, p);", " c->stream = stream;", " char buf1[32], buf2[32], *p;", " time_t ti;", " p = inet_ntoa(c->from_addr.sin_addr);", " strcpy(buf1, p);", " ti = time(NULL);", " p = ctime(&ti);", " strcpy(buf2,...
static int FUNC_0(HTTPContext *VAR_0) { char *VAR_13; int VAR_2; char VAR_3[32]; char VAR_4[1024], *VAR_5; char VAR_6[1024], *VAR_7; char VAR_8[32]; char VAR_9[1024]; const char *VAR_10; FFStream *stream; VAR_13 = VAR_0->buffer; VAR_7 = VAR_3; while (!isspa...
[ "static int FUNC_0(HTTPContext *VAR_0)\n{", "char *VAR_13;", "int VAR_2;", "char VAR_3[32];", "char VAR_4[1024], *VAR_5;", "char VAR_6[1024], *VAR_7;", "char VAR_8[32];", "char VAR_9[1024];", "const char *VAR_10;", "FFStream *stream;", "VAR_13 = VAR_0->buffer;", "VAR_7 = VAR_3;", "while (!is...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1...
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 25 ], [ 27 ], [ 29 ], [ 31, 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41, 43 ], [ 45,...
8,118
static int add_doubles_metadata(int count, const char *name, const char *sep, TiffContext *s) { char *ap; int i; double *dp; if (count >= INT_MAX / sizeof(int64_t) || count <= 0) return AVERROR_INVALIDDATA; if (bytest...
true
FFmpeg
edcc51fb8e15b704955d742559215697598927bb
static int add_doubles_metadata(int count, const char *name, const char *sep, TiffContext *s) { char *ap; int i; double *dp; if (count >= INT_MAX / sizeof(int64_t) || count <= 0) return AVERROR_INVALIDDATA; if (bytest...
{ "code": [ " TiffContext *s)", " av_dict_set(avpriv_frame_get_metadatap(&s->picture), name, ap, AV_DICT_DONT_STRDUP_VAL);", " av_dict_set(avpriv_frame_get_metadatap(&s->picture), name, ap, AV_DICT_DONT_STRDUP_VAL);" ], "line_no": [ 5, 47, 47 ] }
static int FUNC_0(int VAR_0, const char *VAR_1, const char *VAR_2, TiffContext *VAR_3) { char *VAR_4; int VAR_5; double *VAR_6; if (VAR_0 >= INT_MAX / sizeof(int64_t) || VAR_0 <= 0) return AVERROR_INVALIDDATA; if (byt...
[ "static int FUNC_0(int VAR_0,\nconst char *VAR_1, const char *VAR_2,\nTiffContext *VAR_3)\n{", "char *VAR_4;", "int VAR_5;", "double *VAR_6;", "if (VAR_0 >= INT_MAX / sizeof(int64_t) || VAR_0 <= 0)\nreturn AVERROR_INVALIDDATA;", "if (bytestream2_get_bytes_left(&VAR_3->gb) < VAR_0 * sizeof(int64_t))\nretur...
[ 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0 ]
[ [ 1, 3, 5, 7 ], [ 9 ], [ 11 ], [ 13 ], [ 17, 19 ], [ 21, 23 ], [ 27 ], [ 29, 31 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43, 45 ], [ 47 ], [ 49 ], [ 51 ] ]
8,119
static av_cold int che_configure(AACContext *ac, enum ChannelPosition che_pos, int type, int id, int *channels) { if (*channels >= MAX_CHANNELS) return AVERROR_INVALIDDATA; if (che_pos) { if (!ac->che[type][id]) { ...
true
FFmpeg
b99ca863506f0630514921b740b78364de67a3ff
static av_cold int che_configure(AACContext *ac, enum ChannelPosition che_pos, int type, int id, int *channels) { if (*channels >= MAX_CHANNELS) return AVERROR_INVALIDDATA; if (che_pos) { if (!ac->che[type][id]) { ...
{ "code": [ " if (*channels >= MAX_CHANNELS)", " return AVERROR_INVALIDDATA;" ], "line_no": [ 9, 11 ] }
static av_cold int FUNC_0(AACContext *ac, enum ChannelPosition che_pos, int type, int id, int *channels) { if (*channels >= MAX_CHANNELS) return AVERROR_INVALIDDATA; if (che_pos) { if (!ac->che[type][id]) { if ...
[ "static av_cold int FUNC_0(AACContext *ac,\nenum ChannelPosition che_pos,\nint type, int id, int *channels)\n{", "if (*channels >= MAX_CHANNELS)\nreturn AVERROR_INVALIDDATA;", "if (che_pos) {", "if (!ac->che[type][id]) {", "if (!(ac->che[type][id] = av_mallocz(sizeof(ChannelElement))))\nreturn AVERROR(ENOME...
[ 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5, 7 ], [ 9, 11 ], [ 13 ], [ 15 ], [ 17, 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29, 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41, 43 ], [ 45 ], [ 47 ...
8,120
int64_t qdict_get_int(const QDict *qdict, const char *key) { QObject *obj = qdict_get_obj(qdict, key, QTYPE_QINT); return qint_get_int(qobject_to_qint(obj)); }
true
qemu
fcf73f66a67f5e58c18216f8c8651e38cf4d90af
int64_t qdict_get_int(const QDict *qdict, const char *key) { QObject *obj = qdict_get_obj(qdict, key, QTYPE_QINT); return qint_get_int(qobject_to_qint(obj)); }
{ "code": [ " QObject *obj = qdict_get_obj(qdict, key, QTYPE_QINT);", " return qint_get_int(qobject_to_qint(obj));", " return qint_get_int(qobject_to_qint(obj));" ], "line_no": [ 5, 7, 7 ] }
int64_t FUNC_0(const QDict *qdict, const char *key) { QObject *obj = qdict_get_obj(qdict, key, QTYPE_QINT); return qint_get_int(qobject_to_qint(obj)); }
[ "int64_t FUNC_0(const QDict *qdict, const char *key)\n{", "QObject *obj = qdict_get_obj(qdict, key, QTYPE_QINT);", "return qint_get_int(qobject_to_qint(obj));", "}" ]
[ 0, 1, 1, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ] ]
8,121
static target_ulong h_client_architecture_support(PowerPCCPU *cpu, sPAPRMachineState *spapr, target_ulong opcode, target_ulong *args) { target_ulong list = ppc64...
true
qemu
e957f6a9b92439a222ecd4ff1c8cdc9700710c72
static target_ulong h_client_architecture_support(PowerPCCPU *cpu, sPAPRMachineState *spapr, target_ulong opcode, target_ulong *args) { target_ulong list = ppc64...
{ "code": [ " sPAPROptionVector *ov5_guest, *ov5_cas_old, *ov5_updates;" ], "line_no": [ 23 ] }
static target_ulong FUNC_0(PowerPCCPU *cpu, sPAPRMachineState *spapr, target_ulong opcode, target_ulong *args) { target_ulong list = ppc64_phys_to_real(args[0]);...
[ "static target_ulong FUNC_0(PowerPCCPU *cpu,\nsPAPRMachineState *spapr,\ntarget_ulong opcode,\ntarget_ulong *args)\n{", "target_ulong list = ppc64_phys_to_real(args[0]);", "target_ulong ov_table;", "bool explicit_match = false;", "uint32_t max_compat = cpu->max_compat;", "uint32_t best_compat = 0;", "in...
[ 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ [ 1, 3, 5, 7, 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 39 ], [ 41 ], [ 45 ], [ 47 ], [ 49 ], [ 53 ], [ 55 ], [ 57 ], [ 61 ], [...
8,122
static int cbs_read_ue_golomb(CodedBitstreamContext *ctx, BitstreamContext *bc, const char *name, uint32_t *write_to, uint32_t range_min, uint32_t range_max) { uint32_t value; int position; if (ctx->trace_enable) { char bits[65]; ...
false
FFmpeg
44cde38c8acbef7d5250e6d1b52b1020871e093b
static int cbs_read_ue_golomb(CodedBitstreamContext *ctx, BitstreamContext *bc, const char *name, uint32_t *write_to, uint32_t range_min, uint32_t range_max) { uint32_t value; int position; if (ctx->trace_enable) { char bits[65]; ...
{ "code": [], "line_no": [] }
static int FUNC_0(CodedBitstreamContext *VAR_0, BitstreamContext *VAR_1, const char *VAR_2, uint32_t *VAR_3, uint32_t VAR_4, uint32_t VAR_5) { uint32_t value; int VAR_6; if (VAR_0->trace_enable) { char VAR_7[65]; unsigned ...
[ "static int FUNC_0(CodedBitstreamContext *VAR_0, BitstreamContext *VAR_1,\nconst char *VAR_2, uint32_t *VAR_3,\nuint32_t VAR_4, uint32_t VAR_5)\n{", "uint32_t value;", "int VAR_6;", "if (VAR_0->trace_enable) {", "char VAR_7[65];", "unsigned int VAR_8;", "int VAR_9, VAR_10;", "VAR_6 = bitstream_tell(VA...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5, 7 ], [ 9 ], [ 11 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 25 ], [ 29 ], [ 31 ], [ 33 ], [ 35, 37 ], [ 39 ], [ 41 ], [ 43, 45, 47 ], [ 49 ], [ 51 ], [...
8,123
void qmp_block_set_io_throttle(const char *device, int64_t bps, int64_t bps_rd, int64_t bps_wr, int64_t iops, int64_t iops_rd, int64_t iops_wr, bool has_bps_max, ...
true
qemu
b15446fdbf4ac2b29f6ee5080630a80715abfc20
void qmp_block_set_io_throttle(const char *device, int64_t bps, int64_t bps_rd, int64_t bps_wr, int64_t iops, int64_t iops_rd, int64_t iops_wr, bool has_bps_max, ...
{ "code": [], "line_no": [] }
void FUNC_0(const char *VAR_0, int64_t VAR_1, int64_t VAR_2, int64_t VAR_3, int64_t VAR_4, int64_t VAR_5, int64_t VAR_6, bool VAR_7, i...
[ "void FUNC_0(const char *VAR_0, int64_t VAR_1, int64_t VAR_2,\nint64_t VAR_3,\nint64_t VAR_4,\nint64_t VAR_5,\nint64_t VAR_6,\nbool VAR_7,\nint64_t VAR_8,\nbool VAR_9,\nint64_t VAR_10,\nbool VAR_11,\nint64_t VAR_12,\nbool VAR_13,\nint64_t VAR_14,\nbool VAR_15,\nint64_t VAR_16,\nbool VAR_17,\nint64_t VAR_18,\nbool V...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20 ], [ 21 ], [ 22 ], [ 23 ], [ 24 ], [ 25 ], [ 26 ], [ 27 ], [ 28 ], [ 29 ], [ 30 ],...
8,125
void palette8torgb32(const uint8_t *src, uint8_t *dst, long num_pixels, const uint8_t *palette) { long i; /* for(i=0; i<num_pixels; i++) ((unsigned *)dst)[i] = ((unsigned *)palette)[ src[i] ]; */ for(i=0; i<num_pixels; i++) { #ifdef WORDS_BIGENDIAN dst[3]= palette[ src[i]*4+2 ]; dst[2]= pal...
true
FFmpeg
6e42e6c4b410dbef8b593c2d796a5dad95f89ee4
void palette8torgb32(const uint8_t *src, uint8_t *dst, long num_pixels, const uint8_t *palette) { long i; for(i=0; i<num_pixels; i++) { #ifdef WORDS_BIGENDIAN dst[3]= palette[ src[i]*4+2 ]; dst[2]= palette[ src[i]*4+1 ]; dst[1]= palette[ src[i]*4+0 ]; #else dst[0]= palette[ ...
{ "code": [ "\tlong i;", "\tfor(i=0; i<num_pixels; i++)", "\tfor(i=0; i<num_pixels; i++)", "\t\t#ifdef WORDS_BIGENDIAN", "\t\t\tdst[3]= palette[ src[i]*4+2 ];", "\t\t\tdst[2]= palette[ src[i]*4+1 ];", "\t\t\tdst[1]= palette[ src[i]*4+0 ];", "\t\t#else", "\t\t\tdst[0]= palette[ src[...
void FUNC_0(const uint8_t *VAR_0, uint8_t *VAR_1, long VAR_2, const uint8_t *VAR_3) { long VAR_4; for(VAR_4=0; VAR_4<VAR_2; VAR_4++) { #ifdef WORDS_BIGENDIAN VAR_1[3]= VAR_3[ VAR_0[VAR_4]*4+2 ]; VAR_1[2]= VAR_3[ VAR_0[VAR_4]*4+1 ]; VAR_1[1]= VAR_3[ VAR_0[VAR_4]*4+0 ]; #else ...
[ "void FUNC_0(const uint8_t *VAR_0, uint8_t *VAR_1, long VAR_2, const uint8_t *VAR_3)\n{", "long VAR_4;", "for(VAR_4=0; VAR_4<VAR_2; VAR_4++)", "{", "#ifdef WORDS_BIGENDIAN\nVAR_1[3]= VAR_3[ VAR_0[VAR_4]*4+2 ];", "VAR_1[2]= VAR_3[ VAR_0[VAR_4]*4+1 ];", "VAR_1[1]= VAR_3[ VAR_0[VAR_4]*4+0 ];", "#else\nVA...
[ 0, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 19 ], [ 21 ], [ 23, 25 ], [ 27 ], [ 29 ], [ 31, 35 ], [ 37 ], [ 39 ], [ 43, 45 ], [ 47 ], [ 49 ] ]
8,126
const char * avdevice_configuration(void) { return FFMPEG_CONFIGURATION; }
false
FFmpeg
29ba091136a5e04574f7bfc1b17536c923958f6f
const char * avdevice_configuration(void) { return FFMPEG_CONFIGURATION; }
{ "code": [], "line_no": [] }
const char * FUNC_0(void) { return FFMPEG_CONFIGURATION; }
[ "const char * FUNC_0(void)\n{", "return FFMPEG_CONFIGURATION;", "}" ]
[ 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ] ]
8,127
int ff_amf_tag_size(const uint8_t *data, const uint8_t *data_end) { const uint8_t *base = data; if (data >= data_end) return -1; switch (*data++) { case AMF_DATA_TYPE_NUMBER: return 9; case AMF_DATA_TYPE_BOOL: return 2; case AMF_DATA_TYPE_STRING: return 3 + AV_...
true
FFmpeg
3cff53369acdb3bc0695dd6d5df51457fdaa16ce
int ff_amf_tag_size(const uint8_t *data, const uint8_t *data_end) { const uint8_t *base = data; if (data >= data_end) return -1; switch (*data++) { case AMF_DATA_TYPE_NUMBER: return 9; case AMF_DATA_TYPE_BOOL: return 2; case AMF_DATA_TYPE_STRING: return 3 + AV_...
{ "code": [ " if (data + size >= data_end || data + size < data)", " if (t < 0 || data + t >= data_end)", " if (data + size >= data_end || data + size < data)", " if (t < 0 || data + t >= data_end)" ], "line_no": [ 45, 53, 45, 53 ] }
int FUNC_0(const uint8_t *VAR_0, const uint8_t *VAR_1) { const uint8_t *VAR_2 = VAR_0; if (VAR_0 >= VAR_1) return -1; switch (*VAR_0++) { case AMF_DATA_TYPE_NUMBER: return 9; case AMF_DATA_TYPE_BOOL: return 2; case AMF_DATA_TYPE_STRING: return 3 + AV_RB16(VAR_0...
[ "int FUNC_0(const uint8_t *VAR_0, const uint8_t *VAR_1)\n{", "const uint8_t *VAR_2 = VAR_0;", "if (VAR_0 >= VAR_1)\nreturn -1;", "switch (*VAR_0++) {", "case AMF_DATA_TYPE_NUMBER: return 9;", "case AMF_DATA_TYPE_BOOL: return 2;", "case AMF_DATA_TYPE_STRING: return 3 + AV_RB16(VAR_0);", ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 9, 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25, 27 ], [ 29, 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45, 47...
8,128
static int v4l2_read_header(AVFormatContext *s1, AVFormatParameters *ap) { struct video_data *s = s1->priv_data; AVStream *st; int width, height; int res, frame_rate, frame_rate_base; uint32_t desired_format, capabilities; if (ap->width <= 0 || ap->height <= 0 || ap->time_base.den <= 0)...
true
FFmpeg
deaab5fc32134ea53bff2ab46f95dd493ecf94c1
static int v4l2_read_header(AVFormatContext *s1, AVFormatParameters *ap) { struct video_data *s = s1->priv_data; AVStream *st; int width, height; int res, frame_rate, frame_rate_base; uint32_t desired_format, capabilities; if (ap->width <= 0 || ap->height <= 0 || ap->time_base.den <= 0)...
{ "code": [ " av_free(st);", " av_free(st);", " av_free(st);" ], "line_no": [ 79, 79, 79 ] }
static int FUNC_0(AVFormatContext *VAR_0, AVFormatParameters *VAR_1) { struct video_data *VAR_2 = VAR_0->priv_data; AVStream *st; int VAR_3, VAR_4; int VAR_5, VAR_6, VAR_7; uint32_t desired_format, capabilities; if (VAR_1->VAR_3 <= 0 || VAR_1->VAR_4 <= 0 || VAR_1->time_base.den <= 0) { ...
[ "static int FUNC_0(AVFormatContext *VAR_0, AVFormatParameters *VAR_1)\n{", "struct video_data *VAR_2 = VAR_0->priv_data;", "AVStream *st;", "int VAR_3, VAR_4;", "int VAR_5, VAR_6, VAR_7;", "uint32_t desired_format, capabilities;", "if (VAR_1->VAR_3 <= 0 || VAR_1->VAR_4 <= 0 || VAR_1->time_base.den <= 0)...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 17 ], [ 19 ], [ 23 ], [ 25 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 39 ], [ 41 ], [ 45 ], [ 47 ], [ 51 ], [ 53 ...
8,131
const char *bdrv_get_node_name(const BlockDriverState *bs) { return bs->node_name; }
false
qemu
61007b316cd71ee7333ff7a0a749a8949527575f
const char *bdrv_get_node_name(const BlockDriverState *bs) { return bs->node_name; }
{ "code": [], "line_no": [] }
const char *FUNC_0(const BlockDriverState *VAR_0) { return VAR_0->node_name; }
[ "const char *FUNC_0(const BlockDriverState *VAR_0)\n{", "return VAR_0->node_name;", "}" ]
[ 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ] ]
8,132
static unsigned decode_skip_count(GetBitContext* gb) { unsigned value; // This function reads a maximum of 23 bits, // which is within the padding space if (!can_safely_read(gb, 1)) return -1; value = get_bits1(gb); if (!value) return value; value += get_bits(gb, ...
false
FFmpeg
e494f44c051d7dccc038a603ab22532b87dd1705
static unsigned decode_skip_count(GetBitContext* gb) { unsigned value; if (!can_safely_read(gb, 1)) return -1; value = get_bits1(gb); if (!value) return value; value += get_bits(gb, 3); if (value != (1 + ((1 << 3) - 1))) return value; value ...
{ "code": [], "line_no": [] }
static unsigned FUNC_0(GetBitContext* VAR_0) { unsigned VAR_1; if (!can_safely_read(VAR_0, 1)) return -1; VAR_1 = get_bits1(VAR_0); if (!VAR_1) return VAR_1; VAR_1 += get_bits(VAR_0, 3); if (VAR_1 != (1 + ((1 << 3) - 1))) return VAR_1; VAR_1...
[ "static unsigned FUNC_0(GetBitContext* VAR_0)\n{", "unsigned VAR_1;", "if (!can_safely_read(VAR_0, 1))\nreturn -1;", "VAR_1 = get_bits1(VAR_0);", "if (!VAR_1)\nreturn VAR_1;", "VAR_1 += get_bits(VAR_0, 3);", "if (VAR_1 != (1 + ((1 << 3) - 1)))\nreturn VAR_1;", "VAR_1 += get_bits(VAR_0, 7);", "if (VA...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 11, 13 ], [ 15 ], [ 17, 19 ], [ 23 ], [ 25, 27 ], [ 31 ], [ 33, 35 ], [ 39 ], [ 41 ] ]
8,133
void qmp_drive_mirror(const char *device, const char *target, bool has_format, const char *format, bool has_node_name, const char *node_name, bool has_replaces, const char *replaces, enum MirrorSyncMode sync, ...
false
qemu
e12f3784097a26a1ba51be420f41038b4c0ae5d1
void qmp_drive_mirror(const char *device, const char *target, bool has_format, const char *format, bool has_node_name, const char *node_name, bool has_replaces, const char *replaces, enum MirrorSyncMode sync, ...
{ "code": [], "line_no": [] }
void FUNC_0(const char *VAR_0, const char *VAR_1, bool VAR_2, const char *VAR_3, bool VAR_4, const char *VAR_5, bool VAR_6, const char *VAR_7, enum MirrorSyncMode VAR_8, bool VAR_9, enum NewImageMode VAR_1...
[ "void FUNC_0(const char *VAR_0, const char *VAR_1,\nbool VAR_2, const char *VAR_3,\nbool VAR_4, const char *VAR_5,\nbool VAR_6, const char *VAR_7,\nenum MirrorSyncMode VAR_8,\nbool VAR_9, enum NewImageMode VAR_10,\nbool VAR_11, int64_t VAR_12,\nbool VAR_13, uint32_t VAR_14,\nbool VAR_15, int64_t VAR_16,\nbool 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 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ], [ 51 ], [ 53 ], [ 55 ...
8,135
build_rsdp(GArray *rsdp_table, BIOSLinker *linker, unsigned rsdt) { AcpiRsdpDescriptor *rsdp = acpi_data_push(rsdp_table, sizeof *rsdp); bios_linker_loader_alloc(linker, ACPI_BUILD_RSDP_FILE, rsdp_table, 16, true /* fseg memory */); memcpy(&rsdp->signature, "RSD PTR ", ...
false
qemu
4678124bb9bfb49e93b83f95c4d2feeb443ea38b
build_rsdp(GArray *rsdp_table, BIOSLinker *linker, unsigned rsdt) { AcpiRsdpDescriptor *rsdp = acpi_data_push(rsdp_table, sizeof *rsdp); bios_linker_loader_alloc(linker, ACPI_BUILD_RSDP_FILE, rsdp_table, 16, true ); memcpy(&rsdp->signature, "RSD PTR ", 8); memcpy(r...
{ "code": [], "line_no": [] }
FUNC_0(GArray *VAR_0, BIOSLinker *VAR_1, unsigned VAR_2) { AcpiRsdpDescriptor *rsdp = acpi_data_push(VAR_0, sizeof *rsdp); bios_linker_loader_alloc(VAR_1, ACPI_BUILD_RSDP_FILE, VAR_0, 16, true ); memcpy(&rsdp->signature, "RSD PTR ", 8); memcpy(rsdp->oem_id, ACPI_BU...
[ "FUNC_0(GArray *VAR_0, BIOSLinker *VAR_1, unsigned VAR_2)\n{", "AcpiRsdpDescriptor *rsdp = acpi_data_push(VAR_0, sizeof *rsdp);", "bios_linker_loader_alloc(VAR_1, ACPI_BUILD_RSDP_FILE, VAR_0, 16,\ntrue );", "memcpy(&rsdp->signature, \"RSD PTR \", 8);", "memcpy(rsdp->oem_id, ACPI_BUILD_APPNAME6, 6);", "rsd...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 9, 11 ], [ 15 ], [ 17 ], [ 19 ], [ 23, 25, 27, 29 ], [ 31 ], [ 35, 37, 39 ], [ 43 ], [ 45 ] ]
8,136
static int tcp_chr_new_client(CharDriverState *chr, QIOChannelSocket *sioc) { TCPCharDriver *s = chr->opaque; if (s->ioc != NULL) { return -1; } s->ioc = QIO_CHANNEL(sioc); object_ref(OBJECT(sioc)); if (s->do_nodelay) { qio_channel_set_delay(s->ioc, false); } if (...
false
qemu
f2001a7e0555b66d6db25a3ff1801540814045bb
static int tcp_chr_new_client(CharDriverState *chr, QIOChannelSocket *sioc) { TCPCharDriver *s = chr->opaque; if (s->ioc != NULL) { return -1; } s->ioc = QIO_CHANNEL(sioc); object_ref(OBJECT(sioc)); if (s->do_nodelay) { qio_channel_set_delay(s->ioc, false); } if (...
{ "code": [], "line_no": [] }
static int FUNC_0(CharDriverState *VAR_0, QIOChannelSocket *VAR_1) { TCPCharDriver *s = VAR_0->opaque; if (s->ioc != NULL) { return -1; } s->ioc = QIO_CHANNEL(VAR_1); object_ref(OBJECT(VAR_1)); if (s->do_nodelay) { qio_channel_set_delay(s->ioc, false); } if (s->li...
[ "static int FUNC_0(CharDriverState *VAR_0, QIOChannelSocket *VAR_1)\n{", "TCPCharDriver *s = VAR_0->opaque;", "if (s->ioc != NULL) {", "return -1;", "}", "s->ioc = QIO_CHANNEL(VAR_1);", "object_ref(OBJECT(VAR_1));", "if (s->do_nodelay) {", "qio_channel_set_delay(s->ioc, false);", "}", "if (s->li...
[ 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 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 39 ], [ 41 ] ]
8,137
static void q35_host_get_pci_hole64_start(Object *obj, Visitor *v, const char *name, void *opaque, Error **errp) { PCIHostState *h = PCI_HOST_BRIDGE(obj); Range w64; pci_bus_get_w64_range(h->bus, &w64); visit_...
false
qemu
a0efbf16604770b9d805bcf210ec29942321134f
static void q35_host_get_pci_hole64_start(Object *obj, Visitor *v, const char *name, void *opaque, Error **errp) { PCIHostState *h = PCI_HOST_BRIDGE(obj); Range w64; pci_bus_get_w64_range(h->bus, &w64); visit_...
{ "code": [], "line_no": [] }
static void FUNC_0(Object *VAR_0, Visitor *VAR_1, const char *VAR_2, void *VAR_3, Error **VAR_4) { PCIHostState *h = PCI_HOST_BRIDGE(VAR_0); Range w64; pci_bus_get_w64_range(h->bus, &w64); visit_type_uint64(VA...
[ "static void FUNC_0(Object *VAR_0, Visitor *VAR_1,\nconst char *VAR_2, void *VAR_3,\nError **VAR_4)\n{", "PCIHostState *h = PCI_HOST_BRIDGE(VAR_0);", "Range w64;", "pci_bus_get_w64_range(h->bus, &w64);", "visit_type_uint64(VAR_1, VAR_2, &w64.begin, VAR_4);", "}" ]
[ 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5, 7 ], [ 9 ], [ 11 ], [ 15 ], [ 19 ], [ 21 ] ]
8,138
static void dma_mem_writel(void *opaque, target_phys_addr_t addr, uint32_t val) { DMAState *s = opaque; uint32_t saddr; saddr = (addr & DMA_MASK) >> 2; DPRINTF("write dmareg " TARGET_FMT_plx ": 0x%8.8x -> 0x%8.8x\n", addr, s->dmaregs[saddr], val); switch (saddr) { case 0: ...
false
qemu
65899fe34b09ab4af4b045977460b531ec5c1f73
static void dma_mem_writel(void *opaque, target_phys_addr_t addr, uint32_t val) { DMAState *s = opaque; uint32_t saddr; saddr = (addr & DMA_MASK) >> 2; DPRINTF("write dmareg " TARGET_FMT_plx ": 0x%8.8x -> 0x%8.8x\n", addr, s->dmaregs[saddr], val); switch (saddr) { case 0: ...
{ "code": [], "line_no": [] }
static void FUNC_0(void *VAR_0, target_phys_addr_t VAR_1, uint32_t VAR_2) { DMAState *s = VAR_0; uint32_t saddr; saddr = (VAR_1 & DMA_MASK) >> 2; DPRINTF("write dmareg " TARGET_FMT_plx ": 0x%8.8x -> 0x%8.8x\n", VAR_1, s->dmaregs[saddr], VAR_2); switch (saddr) { case 0: ...
[ "static void FUNC_0(void *VAR_0, target_phys_addr_t VAR_1, uint32_t VAR_2)\n{", "DMAState *s = VAR_0;", "uint32_t saddr;", "saddr = (VAR_1 & DMA_MASK) >> 2;", "DPRINTF(\"write dmareg \" TARGET_FMT_plx \": 0x%8.8x -> 0x%8.8x\\n\", VAR_1,\ns->dmaregs[saddr], VAR_2);", "switch (saddr) {", "case 0:\nif (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 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 11 ], [ 13, 15 ], [ 17 ], [ 19, 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45...
8,139
static uint64_t nvic_sysreg_read(void *opaque, target_phys_addr_t addr, unsigned size) { /* At the moment we only support the ID registers for byte/word access. * This is not strictly correct as a few of the other registers also * allow byte access. */ uint...
false
qemu
a8170e5e97ad17ca169c64ba87ae2f53850dab4c
static uint64_t nvic_sysreg_read(void *opaque, target_phys_addr_t addr, unsigned size) { uint32_t offset = addr; if (offset >= 0xfe0) { if (offset & 3) { return 0; } return nvic_id[(offset - 0xfe0) >> 2]; } if (si...
{ "code": [], "line_no": [] }
static uint64_t FUNC_0(void *opaque, target_phys_addr_t addr, unsigned size) { uint32_t offset = addr; if (offset >= 0xfe0) { if (offset & 3) { return 0; } return nvic_id[(offset - 0xfe0) >> 2]; } if (size == 4) {...
[ "static uint64_t FUNC_0(void *opaque, target_phys_addr_t addr,\nunsigned size)\n{", "uint32_t offset = addr;", "if (offset >= 0xfe0) {", "if (offset & 3) {", "return 0;", "}", "return nvic_id[(offset - 0xfe0) >> 2];", "}", "if (size == 4) {", "return nvic_readl(opaque, offset);", "}", "hw_erro...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ] ]
8,140
static void qemu_run_timers(QEMUClock *clock) { QEMUTimer **ptimer_head, *ts; int64_t current_time; if (!clock->enabled) return; current_time = qemu_get_clock (clock); ptimer_head = &active_timers[clock->type]; for(;;) { ts = *ptimer_head; if (!ts || ts->...
false
qemu
4a998740b22aa673ea475060c787da7c545588cf
static void qemu_run_timers(QEMUClock *clock) { QEMUTimer **ptimer_head, *ts; int64_t current_time; if (!clock->enabled) return; current_time = qemu_get_clock (clock); ptimer_head = &active_timers[clock->type]; for(;;) { ts = *ptimer_head; if (!ts || ts->...
{ "code": [], "line_no": [] }
static void FUNC_0(QEMUClock *VAR_0) { QEMUTimer **ptimer_head, *ts; int64_t current_time; if (!VAR_0->enabled) return; current_time = qemu_get_clock (VAR_0); ptimer_head = &active_timers[VAR_0->type]; for(;;) { ts = *ptimer_head; if (!ts || ts->expire_ti...
[ "static void FUNC_0(QEMUClock *VAR_0)\n{", "QEMUTimer **ptimer_head, *ts;", "int64_t current_time;", "if (!VAR_0->enabled)\nreturn;", "current_time = qemu_get_clock (VAR_0);", "ptimer_head = &active_timers[VAR_0->type];", "for(;;) {", "ts = *ptimer_head;", "if (!ts || ts->expire_time > current_time)...
[ 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, 27 ], [ 31 ], [ 33 ], [ 39 ], [ 41 ], [ 43 ] ]
8,141
static void pci_apb_iowriteb (void *opaque, target_phys_addr_t addr, uint32_t val) { cpu_outb(addr & IOPORTS_MASK, val); }
false
qemu
a8170e5e97ad17ca169c64ba87ae2f53850dab4c
static void pci_apb_iowriteb (void *opaque, target_phys_addr_t addr, uint32_t val) { cpu_outb(addr & IOPORTS_MASK, val); }
{ "code": [], "line_no": [] }
static void FUNC_0 (void *VAR_0, target_phys_addr_t VAR_1, uint32_t VAR_2) { cpu_outb(VAR_1 & IOPORTS_MASK, VAR_2); }
[ "static void FUNC_0 (void *VAR_0, target_phys_addr_t VAR_1,\nuint32_t VAR_2)\n{", "cpu_outb(VAR_1 & IOPORTS_MASK, VAR_2);", "}" ]
[ 0, 0, 0 ]
[ [ 1, 3, 5 ], [ 7 ], [ 9 ] ]
8,142
void s390_sclp_extint(uint32_t parm) { if (kvm_enabled()) { kvm_s390_service_interrupt(parm); } else { S390CPU *dummy_cpu = s390_cpu_addr2state(0); cpu_inject_ext(dummy_cpu, EXT_SERVICE, parm, 0); } }
false
qemu
d516f74c99b1a2c289cfba0bacf125cbc9b681e3
void s390_sclp_extint(uint32_t parm) { if (kvm_enabled()) { kvm_s390_service_interrupt(parm); } else { S390CPU *dummy_cpu = s390_cpu_addr2state(0); cpu_inject_ext(dummy_cpu, EXT_SERVICE, parm, 0); } }
{ "code": [], "line_no": [] }
void FUNC_0(uint32_t VAR_0) { if (kvm_enabled()) { kvm_s390_service_interrupt(VAR_0); } else { S390CPU *dummy_cpu = s390_cpu_addr2state(0); cpu_inject_ext(dummy_cpu, EXT_SERVICE, VAR_0, 0); } }
[ "void FUNC_0(uint32_t VAR_0)\n{", "if (kvm_enabled()) {", "kvm_s390_service_interrupt(VAR_0);", "} else {", "S390CPU *dummy_cpu = s390_cpu_addr2state(0);", "cpu_inject_ext(dummy_cpu, EXT_SERVICE, VAR_0, 0);", "}", "}" ]
[ 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 15 ], [ 17 ], [ 19 ] ]
8,143
static int check_init_output_file(OutputFile *of, int file_index) { int ret, i; for (i = 0; i < of->ctx->nb_streams; i++) { OutputStream *ost = output_streams[of->ost_index + i]; if (!ost->initialized) return 0; } of->ctx->interrupt_callback = int_cb; ret =...
false
FFmpeg
c4be288fdbe1993110f1abd28ea57587cb2bc221
static int check_init_output_file(OutputFile *of, int file_index) { int ret, i; for (i = 0; i < of->ctx->nb_streams; i++) { OutputStream *ost = output_streams[of->ost_index + i]; if (!ost->initialized) return 0; } of->ctx->interrupt_callback = int_cb; ret =...
{ "code": [], "line_no": [] }
static int FUNC_0(OutputFile *VAR_0, int VAR_1) { int VAR_2, VAR_3; for (VAR_3 = 0; VAR_3 < VAR_0->ctx->nb_streams; VAR_3++) { OutputStream *ost = output_streams[VAR_0->ost_index + VAR_3]; if (!ost->initialized) return 0; } VAR_0->ctx->interrupt_callback = int_cb;...
[ "static int FUNC_0(OutputFile *VAR_0, int VAR_1)\n{", "int VAR_2, VAR_3;", "for (VAR_3 = 0; VAR_3 < VAR_0->ctx->nb_streams; VAR_3++) {", "OutputStream *ost = output_streams[VAR_0->ost_index + VAR_3];", "if (!ost->initialized)\nreturn 0;", "}", "VAR_0->ctx->interrupt_callback = int_cb;", "VAR_2 = avfor...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 9 ], [ 11 ], [ 13, 15 ], [ 17 ], [ 21 ], [ 25 ], [ 27 ], [ 29, 31, 33, 35 ], [ 37 ], [ 39 ], [ 43 ], [ 47 ], [ 51, 53 ], [ 59 ], [ 61 ], ...
8,144
static void colo_compare_connection(void *opaque, void *user_data) { CompareState *s = user_data; Connection *conn = opaque; Packet *pkt = NULL; GList *result = NULL; int ret; while (!g_queue_is_empty(&conn->primary_list) && !g_queue_is_empty(&conn->secondary_list)) { ...
false
qemu
f4b618360e5a81b097e2e35d52011bec3c63af68
static void colo_compare_connection(void *opaque, void *user_data) { CompareState *s = user_data; Connection *conn = opaque; Packet *pkt = NULL; GList *result = NULL; int ret; while (!g_queue_is_empty(&conn->primary_list) && !g_queue_is_empty(&conn->secondary_list)) { ...
{ "code": [], "line_no": [] }
static void FUNC_0(void *VAR_0, void *VAR_1) { CompareState *s = VAR_1; Connection *conn = VAR_0; Packet *pkt = NULL; GList *result = NULL; int VAR_2; while (!g_queue_is_empty(&conn->primary_list) && !g_queue_is_empty(&conn->secondary_list)) { qemu_mutex_lock(&s->ti...
[ "static void FUNC_0(void *VAR_0, void *VAR_1)\n{", "CompareState *s = VAR_1;", "Connection *conn = VAR_0;", "Packet *pkt = NULL;", "GList *result = NULL;", "int VAR_2;", "while (!g_queue_is_empty(&conn->primary_list) &&\n!g_queue_is_empty(&conn->secondary_list)) {", "qemu_mutex_lock(&s->timer_check_lo...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 17, 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27, 29 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ...
8,146
int main_loop(void *opaque) { struct pollfd ufds[3], *pf, *serial_ufd, *net_ufd, *gdb_ufd; int ret, n, timeout, serial_ok; uint8_t ch; CPUState *env = global_env; if (!term_inited) { /* initialize terminal only there so that the user has a chance to stop QEMU with Ctrl-C...
false
qemu
8f2b1fb008a3bd8964f381c91adf7a7abeccd577
int main_loop(void *opaque) { struct pollfd ufds[3], *pf, *serial_ufd, *net_ufd, *gdb_ufd; int ret, n, timeout, serial_ok; uint8_t ch; CPUState *env = global_env; if (!term_inited) { term_inited = 1; term_init(); } serial_ok = 1; cpu_enable_ti...
{ "code": [], "line_no": [] }
int FUNC_0(void *VAR_0) { struct pollfd VAR_1[3], *pf, *serial_ufd, *net_ufd, *gdb_ufd; int VAR_2, VAR_3, VAR_4, VAR_5; uint8_t ch; CPUState *env = global_env; if (!term_inited) { term_inited = 1; term_init(); } VAR_5 = 1; cpu_enable_ticks(); ...
[ "int FUNC_0(void *VAR_0)\n{", "struct pollfd VAR_1[3], *pf, *serial_ufd, *net_ufd, *gdb_ufd;", "int VAR_2, VAR_3, VAR_4, VAR_5;", "uint8_t ch;", "CPUState *env = global_env;", "if (!term_inited) {", "term_inited = 1;", "term_init();", "}", "VAR_5 = 1;", "cpu_enable_ticks();", "for(;;) {", "V...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 15 ], [ 23 ], [ 25 ], [ 27 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ], [ 49 ], [ 51 ...
8,147
static int get_phys_addr_v5(CPUARMState *env, uint32_t address, int access_type, int is_user, hwaddr *phys_ptr, int *prot, target_ulong *page_size) { CPUState *cs = CPU(arm_env_get_cpu(env)); int code; uint32_t table; uint32_t desc; int...
false
qemu
0c17d68c1d3d6c35f37f5692042d2edb65c8bcc0
static int get_phys_addr_v5(CPUARMState *env, uint32_t address, int access_type, int is_user, hwaddr *phys_ptr, int *prot, target_ulong *page_size) { CPUState *cs = CPU(arm_env_get_cpu(env)); int code; uint32_t table; uint32_t desc; int...
{ "code": [], "line_no": [] }
static int FUNC_0(CPUARMState *VAR_0, uint32_t VAR_1, int VAR_2, int VAR_3, hwaddr *VAR_4, int *VAR_5, target_ulong *VAR_6) { CPUState *cs = CPU(arm_env_get_cpu(VAR_0)); int VAR_7; uint32_t table; uint32_t desc; int VAR_8; int VAR_...
[ "static int FUNC_0(CPUARMState *VAR_0, uint32_t VAR_1, int VAR_2,\nint VAR_3, hwaddr *VAR_4,\nint *VAR_5, target_ulong *VAR_6)\n{", "CPUState *cs = CPU(arm_env_get_cpu(VAR_0));", "int VAR_7;", "uint32_t table;", "uint32_t desc;", "int VAR_8;", "int VAR_9;", "int VAR_10 = 0;", "int VAR_11;", "hwadd...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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 ], [ 33 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ], [ 49 ], [ 51 ...
8,148
static void an5206_init(QEMUMachineInitArgs *args) { ram_addr_t ram_size = args->ram_size; const char *cpu_model = args->cpu_model; const char *kernel_filename = args->kernel_filename; CPUM68KState *env; int kernel_size; uint64_t elf_entry; target_phys_addr_t entry; MemoryRegion...
false
qemu
a8170e5e97ad17ca169c64ba87ae2f53850dab4c
static void an5206_init(QEMUMachineInitArgs *args) { ram_addr_t ram_size = args->ram_size; const char *cpu_model = args->cpu_model; const char *kernel_filename = args->kernel_filename; CPUM68KState *env; int kernel_size; uint64_t elf_entry; target_phys_addr_t entry; MemoryRegion...
{ "code": [], "line_no": [] }
static void FUNC_0(QEMUMachineInitArgs *VAR_0) { ram_addr_t ram_size = VAR_0->ram_size; const char *VAR_1 = VAR_0->VAR_1; const char *VAR_2 = VAR_0->VAR_2; CPUM68KState *env; int VAR_3; uint64_t elf_entry; target_phys_addr_t entry; MemoryRegion *address_space_mem = get_system_me...
[ "static void FUNC_0(QEMUMachineInitArgs *VAR_0)\n{", "ram_addr_t ram_size = VAR_0->ram_size;", "const char *VAR_1 = VAR_0->VAR_1;", "const char *VAR_2 = VAR_0->VAR_2;", "CPUM68KState *env;", "int VAR_3;", "uint64_t elf_entry;", "target_phys_addr_t entry;", "MemoryRegion *address_space_mem = get_syst...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 27, 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 43 ], [ 47 ], [ 49 ], [...
8,150
int cpu_x86_signal_handler(int host_signum, struct siginfo *info, void *puc) { uint32_t *regs = (uint32_t *)(info + 1); void *sigmask = (regs + 20); unsigned long pc; int is_write; uint32_t insn; /* XXX: is there a standard glibc define ? */ pc = re...
false
qemu
e4533c7a8cdcc79ccdf695f0aaa2e23a5b926ed0
int cpu_x86_signal_handler(int host_signum, struct siginfo *info, void *puc) { uint32_t *regs = (uint32_t *)(info + 1); void *sigmask = (regs + 20); unsigned long pc; int is_write; uint32_t insn; pc = regs[1]; is_write = 0; insn = *...
{ "code": [], "line_no": [] }
int FUNC_0(int VAR_0, struct siginfo *VAR_1, void *VAR_2) { uint32_t *regs = (uint32_t *)(VAR_1 + 1); void *VAR_3 = (regs + 20); unsigned long VAR_4; int VAR_5; uint32_t insn; VAR_4 = regs[1]; VAR_5 = 0; insn = *(uint32_t *)VAR_4; ...
[ "int FUNC_0(int VAR_0, struct siginfo *VAR_1,\nvoid *VAR_2)\n{", "uint32_t *regs = (uint32_t *)(VAR_1 + 1);", "void *VAR_3 = (regs + 20);", "unsigned long VAR_4;", "int VAR_5;", "uint32_t insn;", "VAR_4 = regs[1];", "VAR_5 = 0;", "insn = *(uint32_t *)VAR_4;", "if ((insn >> 30) == 3) {", "switch(...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 21 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33, 35, 37, 39, 41, 43, 45, 47 ], [ 49 ], [ 51 ], [ 53 ], [ 55,...
8,151
static void test_visitor_out_native_list_number(TestOutputVisitorData *data, const void *unused) { test_native_list(data, unused, USER_DEF_NATIVE_LIST_UNION_KIND_NUMBER); }
false
qemu
b3db211f3c80bb996a704d665fe275619f728bd4
static void test_visitor_out_native_list_number(TestOutputVisitorData *data, const void *unused) { test_native_list(data, unused, USER_DEF_NATIVE_LIST_UNION_KIND_NUMBER); }
{ "code": [], "line_no": [] }
static void FUNC_0(TestOutputVisitorData *VAR_0, const void *VAR_1) { test_native_list(VAR_0, VAR_1, USER_DEF_NATIVE_LIST_UNION_KIND_NUMBER); }
[ "static void FUNC_0(TestOutputVisitorData *VAR_0,\nconst void *VAR_1)\n{", "test_native_list(VAR_0, VAR_1, USER_DEF_NATIVE_LIST_UNION_KIND_NUMBER);", "}" ]
[ 0, 0, 0 ]
[ [ 1, 3, 5 ], [ 7 ], [ 9 ] ]
8,152
static int read_uncompressed_sgi(unsigned char* out_buf, SgiState *s) { int x, y, z; unsigned int offset = s->height * s->width * s->bytes_per_channel; GetByteContext gp[4]; uint8_t *out_end; /* Test buffer size. */ if (offset * s->depth > bytestream2_get_bytes_left(&s->g)) ret...
true
FFmpeg
60ea0a5236ceac03b8d3ab3b73bda04d04c17273
static int read_uncompressed_sgi(unsigned char* out_buf, SgiState *s) { int x, y, z; unsigned int offset = s->height * s->width * s->bytes_per_channel; GetByteContext gp[4]; uint8_t *out_end; if (offset * s->depth > bytestream2_get_bytes_left(&s->g)) return AVERROR_INVALIDDATA...
{ "code": [ " for (x = s->width; x > 0; x--) {", " bytestream2_get_bufferu(&gp[z], out_end, s->depth);", " out_end += s->depth;" ], "line_no": [ 41, 43, 45 ] }
static int FUNC_0(unsigned char* VAR_0, SgiState *VAR_1) { int VAR_2, VAR_3, VAR_4; unsigned int VAR_5 = VAR_1->height * VAR_1->width * VAR_1->bytes_per_channel; GetByteContext gp[4]; uint8_t *out_end; if (VAR_5 * VAR_1->depth > bytestream2_get_bytes_left(&VAR_1->g)) return AV...
[ "static int FUNC_0(unsigned char* VAR_0, SgiState *VAR_1)\n{", "int VAR_2, VAR_3, VAR_4;", "unsigned int VAR_5 = VAR_1->height * VAR_1->width * VAR_1->bytes_per_channel;", "GetByteContext gp[4];", "uint8_t *out_end;", "if (VAR_5 * VAR_1->depth > bytestream2_get_bytes_left(&VAR_1->g))\nreturn AVERROR_INVAL...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 17, 19 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ], [ 49 ], [ 51 ], [...
8,153
static void rtas_ibm_configure_connector(PowerPCCPU *cpu, sPAPRMachineState *spapr, uint32_t token, uint32_t nargs, target_ulong args, uint32_t nret, ta...
true
qemu
e6fc9568c865f2f81499475a4e322cd563fdfd90
static void rtas_ibm_configure_connector(PowerPCCPU *cpu, sPAPRMachineState *spapr, uint32_t token, uint32_t nargs, target_ulong args, uint32_t nret, ta...
{ "code": [], "line_no": [] }
static void FUNC_0(PowerPCCPU *VAR_0, sPAPRMachineState *VAR_1, uint32_t VAR_2, uint32_t VAR_3, target_ulong VAR_4, uint32_t VAR_5, target_ulong VAR_6) ...
[ "static void FUNC_0(PowerPCCPU *VAR_0,\nsPAPRMachineState *VAR_1,\nuint32_t VAR_2, uint32_t VAR_3,\ntarget_ulong VAR_4, uint32_t VAR_5,\ntarget_ulong VAR_6)\n{", "uint64_t wa_addr;", "uint64_t wa_offset;", "uint32_t drc_index;", "sPAPRDRConnector *drc;", "sPAPRDRConnectorClass *drck;", "sPAPRConfigureCo...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ [ 1, 3, 5, 7, 9, 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 33 ], [ 35 ], [ 37 ], [ 42 ], [ 46 ], [ 48 ], [ 50 ], [ 52,...
8,156
static int64_t seek_to_sector(BlockDriverState *bs, int64_t sector_num) { BDRVBochsState *s = bs->opaque; int64_t offset = sector_num * 512; int64_t extent_index, extent_offset, bitmap_offset; char bitmap_entry; // seek to sector extent_index = offset / s->extent_size; extent_offse...
true
qemu
246f65838d19db6db55bfb41117c35645a2c4789
static int64_t seek_to_sector(BlockDriverState *bs, int64_t sector_num) { BDRVBochsState *s = bs->opaque; int64_t offset = sector_num * 512; int64_t extent_index, extent_offset, bitmap_offset; char bitmap_entry; extent_index = offset / s->extent_size; extent_offset = (offset % s->...
{ "code": [ " int64_t offset = sector_num * 512;", " int64_t extent_index, extent_offset, bitmap_offset;" ], "line_no": [ 7, 9 ] }
static int64_t FUNC_0(BlockDriverState *bs, int64_t sector_num) { BDRVBochsState *s = bs->opaque; int64_t offset = sector_num * 512; int64_t extent_index, extent_offset, bitmap_offset; char VAR_0; extent_index = offset / s->extent_size; extent_offset = (offset % s->extent_size) / ...
[ "static int64_t FUNC_0(BlockDriverState *bs, int64_t sector_num)\n{", "BDRVBochsState *s = bs->opaque;", "int64_t offset = sector_num * 512;", "int64_t extent_index, extent_offset, bitmap_offset;", "char VAR_0;", "extent_index = offset / s->extent_size;", "extent_offset = (offset % s->extent_size) / 512...
[ 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 17 ], [ 19 ], [ 23 ], [ 25 ], [ 27 ], [ 31, 33 ], [ 39, 41 ], [ 43 ], [ 45 ], [ 49 ], [ 51 ], [ 53 ], [ 57 ], [ 59 ...
8,159
static int decode_fctl_chunk(AVFormatContext *s, APNGDemuxContext *ctx, AVPacket *pkt) { uint32_t sequence_number, width, height, x_offset, y_offset; uint16_t delay_num, delay_den; uint8_t dispose_op, blend_op; sequence_number = avio_rb32(s->pb); width = avio_rb32(s->pb); heig...
false
FFmpeg
874eb012f75bc18bb6d79ad4bc0912afa21751f3
static int decode_fctl_chunk(AVFormatContext *s, APNGDemuxContext *ctx, AVPacket *pkt) { uint32_t sequence_number, width, height, x_offset, y_offset; uint16_t delay_num, delay_den; uint8_t dispose_op, blend_op; sequence_number = avio_rb32(s->pb); width = avio_rb32(s->pb); heig...
{ "code": [], "line_no": [] }
static int FUNC_0(AVFormatContext *VAR_0, APNGDemuxContext *VAR_1, AVPacket *VAR_2) { uint32_t sequence_number, width, height, x_offset, y_offset; uint16_t delay_num, delay_den; uint8_t dispose_op, blend_op; sequence_number = avio_rb32(VAR_0->pb); width = avio_rb32(VAR_0->pb); ...
[ "static int FUNC_0(AVFormatContext *VAR_0, APNGDemuxContext *VAR_1, AVPacket *VAR_2)\n{", "uint32_t sequence_number, width, height, x_offset, y_offset;", "uint16_t delay_num, delay_den;", "uint8_t dispose_op, blend_op;", "sequence_number = avio_rb32(VAR_0->pb);", "width = avio_rb32(VAR_0->pb);",...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 37, 39 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ], [...
8,161
static int ape_tag_read_field(AVFormatContext *s) { AVIOContext *pb = s->pb; uint8_t key[1024], *value; uint32_t size, flags; int i, c; size = avio_rl32(pb); /* field size */ flags = avio_rl32(pb); /* field flags */ for (i = 0; i < sizeof(key) - 1; i++) { c = avio_r8(pb);...
false
FFmpeg
c149f67e9b5b4e3b9061e271e75d441bacfa81c6
static int ape_tag_read_field(AVFormatContext *s) { AVIOContext *pb = s->pb; uint8_t key[1024], *value; uint32_t size, flags; int i, c; size = avio_rl32(pb); flags = avio_rl32(pb); for (i = 0; i < sizeof(key) - 1; i++) { c = avio_r8(pb); if (c < 0x20 || c > 0x7...
{ "code": [], "line_no": [] }
static int FUNC_0(AVFormatContext *VAR_0) { AVIOContext *pb = VAR_0->pb; uint8_t key[1024], *value; uint32_t size, flags; int VAR_1, VAR_2; size = avio_rl32(pb); flags = avio_rl32(pb); for (VAR_1 = 0; VAR_1 < sizeof(key) - 1; VAR_1++) { VAR_2 = avio_r8(pb); if ...
[ "static int FUNC_0(AVFormatContext *VAR_0)\n{", "AVIOContext *pb = VAR_0->pb;", "uint8_t key[1024], *value;", "uint32_t size, flags;", "int VAR_1, VAR_2;", "size = avio_rl32(pb);", "flags = avio_rl32(pb);", "for (VAR_1 = 0; VAR_1 < sizeof(key) - 1; VAR_1++) {", "VAR_2 = avio_r8(pb);", "if (VAR_2 <...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23, 25 ], [ 27, 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ...
8,163
static inline void RENAME(rgb2rgb_init)(void) { rgb15to16 = RENAME(rgb15to16); rgb15tobgr24 = RENAME(rgb15tobgr24); rgb15to32 = RENAME(rgb15to32); rgb16tobgr24 = RENAME(rgb16tobgr24); rgb16to32 = RENAME(rgb16to32); rgb16to15 = RENAME(rgb16to15); rgb24tob...
false
FFmpeg
d1adad3cca407f493c3637e20ecd4f7124e69212
static inline void RENAME(rgb2rgb_init)(void) { rgb15to16 = RENAME(rgb15to16); rgb15tobgr24 = RENAME(rgb15tobgr24); rgb15to32 = RENAME(rgb15to32); rgb16tobgr24 = RENAME(rgb16tobgr24); rgb16to32 = RENAME(rgb16to32); rgb16to15 = RENAME(rgb16to15); rgb24tob...
{ "code": [], "line_no": [] }
static inline void FUNC_0(rgb2rgb_init)(void) { rgb15to16 = FUNC_0(rgb15to16); rgb15tobgr24 = FUNC_0(rgb15tobgr24); rgb15to32 = FUNC_0(rgb15to32); rgb16tobgr24 = FUNC_0(rgb16tobgr24); rgb16to32 = FUNC_0(rgb16to32); rgb16to15 = FUNC_0(rgb16to15); rgb24tob...
[ "static inline void FUNC_0(rgb2rgb_init)(void)\n{", "rgb15to16 = FUNC_0(rgb15to16);", "rgb15tobgr24 = FUNC_0(rgb15tobgr24);", "rgb15to32 = FUNC_0(rgb15to32);", "rgb16tobgr24 = FUNC_0(rgb16tobgr24);", "rgb16to32 = FUNC_0(rgb16to32);", "rgb16to15 = FUNC_0(rgb16to15);", "rgb...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ...
8,165
static av_always_inline int vc1_filter_line(uint8_t* src, int stride, int pq){ uint8_t *cm = ff_cropTbl + MAX_NEG_CROP; int a0 = (2*(src[-2*stride] - src[ 1*stride]) - 5*(src[-1*stride] - src[ 0*stride]) + 4) >> 3; int a0_sign = a0 >> 31; /* Store sign */ a0 = (a0 ^ a0_sign) - a0_sign; /* a...
false
FFmpeg
0e58865d6e86bbb664d92311c0f81c65e0213c35
static av_always_inline int vc1_filter_line(uint8_t* src, int stride, int pq){ uint8_t *cm = ff_cropTbl + MAX_NEG_CROP; int a0 = (2*(src[-2*stride] - src[ 1*stride]) - 5*(src[-1*stride] - src[ 0*stride]) + 4) >> 3; int a0_sign = a0 >> 31; a0 = (a0 ^ a0_sign) - a0_sign; if(a0 < pq){ ...
{ "code": [], "line_no": [] }
static av_always_inline int FUNC_0(uint8_t* src, int stride, int pq){ uint8_t *cm = ff_cropTbl + MAX_NEG_CROP; int VAR_0 = (2*(src[-2*stride] - src[ 1*stride]) - 5*(src[-1*stride] - src[ 0*stride]) + 4) >> 3; int VAR_1 = VAR_0 >> 31; VAR_0 = (VAR_0 ^ VAR_1) - VAR_1; if(VAR_0 < pq){ ...
[ "static av_always_inline int FUNC_0(uint8_t* src, int stride, int pq){", "uint8_t *cm = ff_cropTbl + MAX_NEG_CROP;", "int VAR_0 = (2*(src[-2*stride] - src[ 1*stride]) - 5*(src[-1*stride] - src[ 0*stride]) + 4) >> 3;", "int VAR_1 = VAR_0 >> 31;", "VAR_0 = (VAR_0 ^ VAR_1) - VAR_1;", "if(VAR_0 < pq){", "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 ]
[ [ 1 ], [ 3 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 41, 43 ], [ 45...
8,166
static av_cold void RENAME(sws_init_swScale)(SwsContext *c) { enum PixelFormat srcFormat = c->srcFormat, dstFormat = c->dstFormat; if (!is16BPS(dstFormat) && !is9_OR_10BPS(dstFormat)) { if (!(c->flags & SWS_BITEXACT)) { if (c->flags & SWS_ACCURATE_RND) { ...
true
FFmpeg
0d994b2f45c08794899057ee7ca54f48218c0a53
static av_cold void RENAME(sws_init_swScale)(SwsContext *c) { enum PixelFormat srcFormat = c->srcFormat, dstFormat = c->dstFormat; if (!is16BPS(dstFormat) && !is9_OR_10BPS(dstFormat)) { if (!(c->flags & SWS_BITEXACT)) { if (c->flags & SWS_ACCURATE_RND) { ...
{ "code": [ " if (!is16BPS(dstFormat) && !is9_OR_10BPS(dstFormat)) {" ], "line_no": [ 11 ] }
static av_cold void FUNC_0(sws_init_swScale)(SwsContext *c) { enum PixelFormat VAR_0 = c->VAR_0, VAR_1 = c->VAR_1; if (!is16BPS(VAR_1) && !is9_OR_10BPS(VAR_1)) { if (!(c->flags & SWS_BITEXACT)) { if (c->flags & SWS_ACCURATE_RND) { c->yuv2yuv1 = F...
[ "static av_cold void FUNC_0(sws_init_swScale)(SwsContext *c)\n{", "enum PixelFormat VAR_0 = c->VAR_0,\nVAR_1 = c->VAR_1;", "if (!is16BPS(VAR_1) && !is9_OR_10BPS(VAR_1)) {", "if (!(c->flags & SWS_BITEXACT)) {", "if (c->flags & SWS_ACCURATE_RND) {", "c->yuv2yuv1 = FUNC_0(yuv2yuv1_ar );", "c->yuv2yuvX =...
[ 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, 0, 0...
[ [ 1, 3 ], [ 5, 7 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], ...
8,167
static void new_subtitle_stream(AVFormatContext *oc) { AVStream *st; AVCodec *codec=NULL; AVCodecContext *subtitle_enc; st = av_new_stream(oc, oc->nb_streams < nb_streamid_map ? streamid_map[oc->nb_streams] : 0); if (!st) { fprintf(stderr, "Could not alloc stream\n"); ffmpe...
true
FFmpeg
ca8064d2d1b293d7a8011bf0a08005c11ae8ba67
static void new_subtitle_stream(AVFormatContext *oc) { AVStream *st; AVCodec *codec=NULL; AVCodecContext *subtitle_enc; st = av_new_stream(oc, oc->nb_streams < nb_streamid_map ? streamid_map[oc->nb_streams] : 0); if (!st) { fprintf(stderr, "Could not alloc stream\n"); ffmpe...
{ "code": [ " bitstream_filters[nb_output_files] =", " grow_array(bitstream_filters[nb_output_files],", " sizeof(*bitstream_filters[nb_output_files]),", " &nb_bitstream_filters[nb_output_files], oc->nb_streams);", " bitstream_filters[nb_output_files...
static void FUNC_0(AVFormatContext *VAR_0) { AVStream *st; AVCodec *codec=NULL; AVCodecContext *subtitle_enc; st = av_new_stream(VAR_0, VAR_0->nb_streams < nb_streamid_map ? streamid_map[VAR_0->nb_streams] : 0); if (!st) { fprintf(stderr, "Could not alloc stream\n"); ffmpeg...
[ "static void FUNC_0(AVFormatContext *VAR_0)\n{", "AVStream *st;", "AVCodec *codec=NULL;", "AVCodecContext *subtitle_enc;", "st = av_new_stream(VAR_0, VAR_0->nb_streams < nb_streamid_map ? streamid_map[VAR_0->nb_streams] : 0);", "if (!st) {", "fprintf(stderr, \"Could not alloc stream\\n\");", "ffmpeg_e...
[ 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 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29, 31 ], [ 33 ], [ 35 ], [ 37 ], [ 41, 43, 45, 47 ], [ 49 ...
8,170
static int qemu_rdma_registration_handle(QEMUFile *f, void *opaque) { RDMAControlHeader reg_resp = { .len = sizeof(RDMARegisterResult), .type = RDMA_CONTROL_REGISTER_RESULT, .repeat = 0, }; RDMAControlHeader unreg_r...
true
qemu
afcddefdbe75d0c20bf6e11b5512ba768ce0700c
static int qemu_rdma_registration_handle(QEMUFile *f, void *opaque) { RDMAControlHeader reg_resp = { .len = sizeof(RDMARegisterResult), .type = RDMA_CONTROL_REGISTER_RESULT, .repeat = 0, }; RDMAControlHeader unreg_r...
{ "code": [], "line_no": [] }
static int FUNC_0(QEMUFile *VAR_0, void *VAR_1) { RDMAControlHeader reg_resp = { .len = sizeof(RDMARegisterResult), .type = RDMA_CONTROL_REGISTER_RESULT, .repeat = 0, }; RDMAControlHeader unreg_resp = { .len = 0, ...
[ "static int FUNC_0(QEMUFile *VAR_0, void *VAR_1)\n{", "RDMAControlHeader reg_resp = { .len = sizeof(RDMARegisterResult),", ".type = RDMA_CONTROL_REGISTER_RESULT,\n.repeat = 0,\n};", "RDMAControlHeader unreg_resp = { .len = 0,", ".type = RDMA_CONTROL_UNREGISTER_FINISHED,\n.repeat = 0,\n};", "RDMAControlHea...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ [ 1, 3 ], [ 5 ], [ 7, 9, 11 ], [ 13 ], [ 15, 17, 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ...
8,172
static void set_sigmask(const sigset_t *set) { do_sigprocmask(SIG_SETMASK, set, NULL); }
true
qemu
3d3efba020da1de57a715e2087cf761ed0ad0904
static void set_sigmask(const sigset_t *set) { do_sigprocmask(SIG_SETMASK, set, NULL); }
{ "code": [ " do_sigprocmask(SIG_SETMASK, set, NULL);" ], "line_no": [ 5 ] }
static void FUNC_0(const sigset_t *VAR_0) { do_sigprocmask(SIG_SETMASK, VAR_0, NULL); }
[ "static void FUNC_0(const sigset_t *VAR_0)\n{", "do_sigprocmask(SIG_SETMASK, VAR_0, NULL);", "}" ]
[ 0, 1, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ] ]
8,174
int qcow2_grow_l1_table(BlockDriverState *bs, uint64_t min_size, bool exact_size) { BDRVQcowState *s = bs->opaque; int new_l1_size2, ret, i; uint64_t *new_l1_table; int64_t old_l1_table_offset, old_l1_size; int64_t new_l1_table_offset, new_l1_size; uint8_t data[12]; i...
true
qemu
b93f995081cc32e56071fef179161d2907d0491e
int qcow2_grow_l1_table(BlockDriverState *bs, uint64_t min_size, bool exact_size) { BDRVQcowState *s = bs->opaque; int new_l1_size2, ret, i; uint64_t *new_l1_table; int64_t old_l1_table_offset, old_l1_size; int64_t new_l1_table_offset, new_l1_size; uint8_t data[12]; i...
{ "code": [], "line_no": [] }
int FUNC_0(BlockDriverState *VAR_0, uint64_t VAR_1, bool VAR_2) { BDRVQcowState *s = VAR_0->opaque; int VAR_3, VAR_4, VAR_5; uint64_t *new_l1_table; int64_t old_l1_table_offset, old_l1_size; int64_t new_l1_table_offset, new_l1_size; uint8_t data[12]; if (VAR_1 <= s->l...
[ "int FUNC_0(BlockDriverState *VAR_0, uint64_t VAR_1,\nbool VAR_2)\n{", "BDRVQcowState *s = VAR_0->opaque;", "int VAR_3, VAR_4, VAR_5;", "uint64_t *new_l1_table;", "int64_t old_l1_table_offset, old_l1_size;", "int64_t new_l1_table_offset, new_l1_size;", "uint8_t data[12];", "if (VAR_1 <= s->l1_size)\nr...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 2, 3 ], [ 4 ], [ 5 ], [ 6 ], [ 7 ], [ 8 ], [ 9 ], [ 10, 11 ], [ 12 ], [ 13 ], [ 14 ], [ 16 ], [ 17 ], [ 18 ], [ 19 ], [ 20 ], [ 21 ], [ 22, 23, 24 ],...
8,175
static void test_submit_aio(void) { WorkerTestData data = { .n = 0, .ret = -EINPROGRESS }; data.aiocb = thread_pool_submit_aio(pool, worker_cb, &data, done_cb, &data); /* The callbacks are not called until after the first wait. */ active = 1; g_asser...
true
qemu
35ecde26018207fe723bec6efbd340db6e9c2d53
static void test_submit_aio(void) { WorkerTestData data = { .n = 0, .ret = -EINPROGRESS }; data.aiocb = thread_pool_submit_aio(pool, worker_cb, &data, done_cb, &data); active = 1; g_assert_cmpint(data.ret, ==, -EINPROGRESS); qemu_aio_wait_all();...
{ "code": [ " qemu_aio_wait_all();", " qemu_aio_wait_all();", " qemu_aio_wait_all();", " qemu_aio_wait_all();" ], "line_no": [ 19, 19, 19, 19 ] }
static void FUNC_0(void) { WorkerTestData data = { .n = 0, .ret = -EINPROGRESS }; data.aiocb = thread_pool_submit_aio(pool, worker_cb, &data, done_cb, &data); active = 1; g_assert_cmpint(data.ret, ==, -EINPROGRESS); qemu_aio_wait_all(); g_a...
[ "static void FUNC_0(void)\n{", "WorkerTestData data = { .n = 0, .ret = -EINPROGRESS };", "data.aiocb = thread_pool_submit_aio(pool, worker_cb, &data,\ndone_cb, &data);", "active = 1;", "g_assert_cmpint(data.ret, ==, -EINPROGRESS);", "qemu_aio_wait_all();", "g_assert_cmpint(active, ==, 0);", "g_assert_...
[ 0, 0, 0, 0, 0, 1, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7, 9 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ] ]
8,176
static inline void silk_stabilize_lsf(int16_t nlsf[16], int order, const uint16_t min_delta[17]) { int pass, i; for (pass = 0; pass < 20; pass++) { int k, min_diff = 0; for (i = 0; i < order+1; i++) { int low = i != 0 ? nlsf[i-1] : 0; int high = i != order ? n...
true
FFmpeg
4654baff125d937ae0b1037aa5f0bf53c7351658
static inline void silk_stabilize_lsf(int16_t nlsf[16], int order, const uint16_t min_delta[17]) { int pass, i; for (pass = 0; pass < 20; pass++) { int k, min_diff = 0; for (i = 0; i < order+1; i++) { int low = i != 0 ? nlsf[i-1] : 0; int high = i != order ? n...
{ "code": [ " if (nlsf[i] < nlsf[i - 1] + min_delta[i])", " nlsf[i] = nlsf[i - 1] + min_delta[i];" ], "line_no": [ 133, 135 ] }
static inline void FUNC_0(int16_t VAR_0[16], int VAR_1, const uint16_t VAR_2[17]) { int VAR_3, VAR_4; for (VAR_3 = 0; VAR_3 < 20; VAR_3++) { int VAR_5, VAR_6 = 0; for (VAR_4 = 0; VAR_4 < VAR_1+1; VAR_4++) { int VAR_7 = VAR_4 != 0 ? VAR_0[VAR_4-1] : 0; int VAR_...
[ "static inline void FUNC_0(int16_t VAR_0[16], int VAR_1, const uint16_t VAR_2[17])\n{", "int VAR_3, VAR_4;", "for (VAR_3 = 0; VAR_3 < 20; VAR_3++) {", "int VAR_5, VAR_6 = 0;", "for (VAR_4 = 0; VAR_4 < VAR_1+1; VAR_4++) {", "int VAR_7 = VAR_4 != 0 ? VAR_0[VAR_4-1] : 0;", "int VAR_8 = VAR_4 != 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, 1, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 21 ], [ 23 ], [ 25 ], [ 29, 31 ], [ 33 ], [ 35 ], [ 37, 39 ], [ 45 ], [ 49 ], [ 51 ], [ 55 ...
8,178
static void virtio_scsi_handle_ctrl(VirtIODevice *vdev, VirtQueue *vq) { VirtIOSCSI *s = (VirtIOSCSI *)vdev; VirtIOSCSIReq *req; if (s->ctx && !s->dataplane_started) { virtio_scsi_dataplane_start(s); return; } while ((req = virtio_scsi_pop_req(s, vq))) { virtio_scs...
true
qemu
a8f2e5c8fffbaf7fbd4f0efc8efbeebade78008f
static void virtio_scsi_handle_ctrl(VirtIODevice *vdev, VirtQueue *vq) { VirtIOSCSI *s = (VirtIOSCSI *)vdev; VirtIOSCSIReq *req; if (s->ctx && !s->dataplane_started) { virtio_scsi_dataplane_start(s); return; } while ((req = virtio_scsi_pop_req(s, vq))) { virtio_scs...
{ "code": [ "static void virtio_scsi_handle_ctrl(VirtIODevice *vdev, VirtQueue *vq)", " VirtIOSCSI *s = (VirtIOSCSI *)vdev;", " if (s->ctx && !s->dataplane_started) {", " virtio_scsi_dataplane_start(s);", " VirtIOSCSI *s = (VirtIOSCSI *)vdev;", " if (s->ctx && !s->dataplane_...
static void FUNC_0(VirtIODevice *VAR_0, VirtQueue *VAR_1) { VirtIOSCSI *s = (VirtIOSCSI *)VAR_0; VirtIOSCSIReq *req; if (s->ctx && !s->dataplane_started) { virtio_scsi_dataplane_start(s); return; } while ((req = virtio_scsi_pop_req(s, VAR_1))) { virtio_scsi_handle_...
[ "static void FUNC_0(VirtIODevice *VAR_0, VirtQueue *VAR_1)\n{", "VirtIOSCSI *s = (VirtIOSCSI *)VAR_0;", "VirtIOSCSIReq *req;", "if (s->ctx && !s->dataplane_started) {", "virtio_scsi_dataplane_start(s);", "return;", "}", "while ((req = virtio_scsi_pop_req(s, VAR_1))) {", "virtio_scsi_handle_ctrl_req(...
[ 1, 1, 0, 1, 1, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ] ]
8,179
static int decode_channel_sound_unit(ATRAC3Context *q, GetBitContext *gb, ChannelUnit *snd, float *output, int channel_num, int coding_mode) { int band, ret, num_subbands, last_tonal, num_bands; GainBlock *gain1 = &snd->gain_block[ ...
false
FFmpeg
c61b28e0421f0f9502dfb21495a03cda191def15
static int decode_channel_sound_unit(ATRAC3Context *q, GetBitContext *gb, ChannelUnit *snd, float *output, int channel_num, int coding_mode) { int band, ret, num_subbands, last_tonal, num_bands; GainBlock *gain1 = &snd->gain_block[ ...
{ "code": [], "line_no": [] }
static int FUNC_0(ATRAC3Context *VAR_0, GetBitContext *VAR_1, ChannelUnit *VAR_2, float *VAR_3, int VAR_4, int VAR_5) { int VAR_6, VAR_7, VAR_8, VAR_9, VAR_10; GainBlock *gain1 = &VAR_2->gain_block[ VAR_2->gc_blk_switch]; Gai...
[ "static int FUNC_0(ATRAC3Context *VAR_0, GetBitContext *VAR_1,\nChannelUnit *VAR_2, float *VAR_3,\nint VAR_4, int VAR_5)\n{", "int VAR_6, VAR_7, VAR_8, VAR_9, VAR_10;", "GainBlock *gain1 = &VAR_2->gain_block[ VAR_2->gc_blk_switch];", "GainBlock *gain2 = &VAR_2->gain_block[1 - VAR_2->gc_blk_switch];", "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 ]
[ [ 1, 3, 5, 7 ], [ 9 ], [ 11 ], [ 13 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 43 ], [ 47 ], [ 49, 51 ], [...
8,180
static void RENAME(extract_odd2)(const uint8_t *src, uint8_t *dst0, uint8_t *dst1, x86_reg count) { dst0+= count; dst1+= count; src += 4*count; count= - count; #if COMPILE_TEMPLATE_MMX if(count <= -8) { count += 7; __asm__ volatile( "pcmpeqw %%mm7, %%m...
false
FFmpeg
d1adad3cca407f493c3637e20ecd4f7124e69212
static void RENAME(extract_odd2)(const uint8_t *src, uint8_t *dst0, uint8_t *dst1, x86_reg count) { dst0+= count; dst1+= count; src += 4*count; count= - count; #if COMPILE_TEMPLATE_MMX if(count <= -8) { count += 7; __asm__ volatile( "pcmpeqw %%mm7, %%m...
{ "code": [], "line_no": [] }
static void FUNC_0(extract_odd2)(const uint8_t *src, uint8_t *dst0, uint8_t *dst1, x86_reg count) { dst0+= count; dst1+= count; src += 4*count; count= - count; #if COMPILE_TEMPLATE_MMX if(count <= -8) { count += 7; __asm__ volatile( "pcmpeqw %%mm7, %%m...
[ "static void FUNC_0(extract_odd2)(const uint8_t *src, uint8_t *dst0, uint8_t *dst1, x86_reg count)\n{", "dst0+= count;", "dst1+= count;", "src += 4*count;", "count= - count;", "#if COMPILE_TEMPLATE_MMX\nif(count <= -8) {", "count += 7;", "__asm__ volatile(\n\"pcmpeqw %%mm7, %%mm7 \\n\...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13, 15 ], [ 17 ], [ 19, 21, 23, 25, 27, 29, 31, 33, 35, 37, 39, 41, 43, 45, 47, 49, 51, 53, 55, 57, 59, 61, 63, 65,...
8,183
static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, AVPacket *avpkt) { const uint8_t *buf = avpkt->data; int buf_size = avpkt->size; H264Context *h = avctx->priv_data; MpegEncContext *s = &h->s; AVFrame *pict = ...
false
FFmpeg
87e302bfd8ffbc6cdb20920029013956b10ace63
static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, AVPacket *avpkt) { const uint8_t *buf = avpkt->data; int buf_size = avpkt->size; H264Context *h = avctx->priv_data; MpegEncContext *s = &h->s; AVFrame *pict = ...
{ "code": [], "line_no": [] }
static int FUNC_0(AVCodecContext *VAR_0, void *VAR_1, int *VAR_2, AVPacket *VAR_3) { const uint8_t *VAR_4 = VAR_3->VAR_1; int VAR_5 = VAR_3->size; H264Context *h = VAR_0->priv_data; MpegEncContext *s = &h->s; AVFrame *pict = VAR_1; ...
[ "static int FUNC_0(AVCodecContext *VAR_0,\nvoid *VAR_1, int *VAR_2,\nAVPacket *VAR_3)\n{", "const uint8_t *VAR_4 = VAR_3->VAR_1;", "int VAR_5 = VAR_3->size;", "H264Context *h = VAR_0->priv_data;", "MpegEncContext *s = &h->s;", "AVFrame *pict = VAR_1;", "int VAR_6;", "s->flags= VAR_0->flags;", "s->fl...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ [ 1, 3, 5, 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 23 ], [ 25 ], [ 31 ], [ 33 ], [ 35 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ], [ 49 ], [ 51 ], [ 53 ...
8,184
static int tscc2_decode_mb(TSCC2Context *c, int *q, int vlc_set, uint8_t *dst, int stride, int plane) { GetBitContext *gb = &c->gb; int prev_dc, dc, nc, ac, bpos, val; int i, j, k, l; if (get_bits1(gb)) { if (get_bits1(gb)) { val = get_bits(gb, 8)...
false
FFmpeg
927d866a9961c17597744436c8508703c2dc8277
static int tscc2_decode_mb(TSCC2Context *c, int *q, int vlc_set, uint8_t *dst, int stride, int plane) { GetBitContext *gb = &c->gb; int prev_dc, dc, nc, ac, bpos, val; int i, j, k, l; if (get_bits1(gb)) { if (get_bits1(gb)) { val = get_bits(gb, 8)...
{ "code": [], "line_no": [] }
static int FUNC_0(TSCC2Context *VAR_0, int *VAR_1, int VAR_2, uint8_t *VAR_3, int VAR_4, int VAR_5) { GetBitContext *gb = &VAR_0->gb; int VAR_6, VAR_7, VAR_8, VAR_9, VAR_10, VAR_11; int VAR_12, VAR_13, VAR_14, VAR_15; if (get_bits1(gb)) { if (get_bits1(gb)) { ...
[ "static int FUNC_0(TSCC2Context *VAR_0, int *VAR_1, int VAR_2,\nuint8_t *VAR_3, int VAR_4, int VAR_5)\n{", "GetBitContext *gb = &VAR_0->gb;", "int VAR_6, VAR_7, VAR_8, VAR_9, VAR_10, VAR_11;", "int VAR_12, VAR_13, VAR_14, VAR_15;", "if (get_bits1(gb)) {", "if (get_bits1(gb)) {", "VAR_11 = get_bits(gb, 8...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5 ], [ 7 ], [ 9 ], [ 11 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27, 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ...
8,185
static void subband_transform(DCAEncContext *c, const int32_t *input) { int ch, subs, i, k, j; for (ch = 0; ch < c->fullband_channels; ch++) { /* History is copied because it is also needed for PSY */ int32_t hist[512]; int hist_start = 0; const int chi = c->channel_orde...
false
FFmpeg
a6191d098a03f94685ae4c072bfdf10afcd86223
static void subband_transform(DCAEncContext *c, const int32_t *input) { int ch, subs, i, k, j; for (ch = 0; ch < c->fullband_channels; ch++) { int32_t hist[512]; int hist_start = 0; const int chi = c->channel_order_tab[ch]; for (i = 0; i < 512; i++) ...
{ "code": [], "line_no": [] }
static void FUNC_0(DCAEncContext *VAR_0, const int32_t *VAR_1) { int VAR_2, VAR_3, VAR_4, VAR_5, VAR_6; for (VAR_2 = 0; VAR_2 < VAR_0->fullband_channels; VAR_2++) { int32_t hist[512]; int hist_start = 0; const int chi = VAR_0->channel_order_tab[VAR_2]; for (V...
[ "static void FUNC_0(DCAEncContext *VAR_0, const int32_t *VAR_1)\n{", "int VAR_2, VAR_3, VAR_4, VAR_5, VAR_6;", "for (VAR_2 = 0; VAR_2 < VAR_0->fullband_channels; VAR_2++) {", "int32_t hist[512];", "int hist_start = 0;", "const int chi = VAR_0->channel_order_tab[VAR_2];", "for (VAR_4 = 0; VAR_4 < 512; VA...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 9 ], [ 13 ], [ 15 ], [ 17 ], [ 21 ], [ 23 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 39 ], [ 41 ], [ 45 ], [ 47 ], [ 49 ], [ 51 ], [ 53 ], [ 57...
8,186
static void test_in_coroutine(void) { Coroutine *coroutine; g_assert(!qemu_in_coroutine()); coroutine = qemu_coroutine_create(verify_in_coroutine); qemu_coroutine_enter(coroutine, NULL); }
true
qemu
0b8b8753e4d94901627b3e86431230f2319215c4
static void test_in_coroutine(void) { Coroutine *coroutine; g_assert(!qemu_in_coroutine()); coroutine = qemu_coroutine_create(verify_in_coroutine); qemu_coroutine_enter(coroutine, NULL); }
{ "code": [ " coroutine = qemu_coroutine_create(verify_in_coroutine);", " qemu_coroutine_enter(coroutine, NULL);" ], "line_no": [ 13, 15 ] }
static void FUNC_0(void) { Coroutine *coroutine; g_assert(!qemu_in_coroutine()); coroutine = qemu_coroutine_create(verify_in_coroutine); qemu_coroutine_enter(coroutine, NULL); }
[ "static void FUNC_0(void)\n{", "Coroutine *coroutine;", "g_assert(!qemu_in_coroutine());", "coroutine = qemu_coroutine_create(verify_in_coroutine);", "qemu_coroutine_enter(coroutine, NULL);", "}" ]
[ 0, 0, 0, 1, 1, 0 ]
[ [ 1, 3 ], [ 5 ], [ 9 ], [ 13 ], [ 15 ], [ 17 ] ]
8,187
static void pcx_palette(const uint8_t **src, uint32_t *dst, unsigned int pallen) { unsigned int i; for (i=0; i<pallen; i++) *dst++ = 0xFF000000 | bytestream_get_be24(src); if (pallen < 256) memset(dst, 0, (256 - pallen) * sizeof(*dst)); }
true
FFmpeg
8cd1c0febe88b757e915e9af15559575c21ca728
static void pcx_palette(const uint8_t **src, uint32_t *dst, unsigned int pallen) { unsigned int i; for (i=0; i<pallen; i++) *dst++ = 0xFF000000 | bytestream_get_be24(src); if (pallen < 256) memset(dst, 0, (256 - pallen) * sizeof(*dst)); }
{ "code": [ "static void pcx_palette(const uint8_t **src, uint32_t *dst, unsigned int pallen) {", " unsigned int i;", " *dst++ = 0xFF000000 | bytestream_get_be24(src);" ], "line_no": [ 1, 3, 9 ] }
static void FUNC_0(const uint8_t **VAR_0, uint32_t *VAR_1, unsigned int VAR_2) { unsigned int VAR_3; for (VAR_3=0; VAR_3<VAR_2; VAR_3++) *VAR_1++ = 0xFF000000 | bytestream_get_be24(VAR_0); if (VAR_2 < 256) memset(VAR_1, 0, (256 - VAR_2) * sizeof(*VAR_1)); }
[ "static void FUNC_0(const uint8_t **VAR_0, uint32_t *VAR_1, unsigned int VAR_2) {", "unsigned int VAR_3;", "for (VAR_3=0; VAR_3<VAR_2; VAR_3++)", "*VAR_1++ = 0xFF000000 | bytestream_get_be24(VAR_0);", "if (VAR_2 < 256)\nmemset(VAR_1, 0, (256 - VAR_2) * sizeof(*VAR_1));", "}" ]
[ 1, 1, 0, 1, 0, 0 ]
[ [ 1 ], [ 3 ], [ 7 ], [ 9 ], [ 11, 13 ], [ 15 ] ]
8,188
block_crypto_open_opts_init(QCryptoBlockFormat format, QemuOpts *opts, Error **errp) { OptsVisitor *ov; QCryptoBlockOpenOptions *ret = NULL; Error *local_err = NULL; ret = g_new0(QCryptoBlockOpenOptions, 1); ret->format = format; ...
true
qemu
95c3df5a24e2f18129b58691c2ebaf0d86808525
block_crypto_open_opts_init(QCryptoBlockFormat format, QemuOpts *opts, Error **errp) { OptsVisitor *ov; QCryptoBlockOpenOptions *ret = NULL; Error *local_err = NULL; ret = g_new0(QCryptoBlockOpenOptions, 1); ret->format = format; ...
{ "code": [ " error_propagate(errp, local_err);", " local_err = NULL;", " visit_end_struct(opts_get_visitor(ov), &local_err);", " error_propagate(errp, local_err);", " local_err = NULL;", " visit_end_struct(opts_get_visitor(ov), &local_err);" ], "line_no": [ 59, 6...
FUNC_0(QCryptoBlockFormat VAR_0, QemuOpts *VAR_1, Error **VAR_2) { OptsVisitor *ov; QCryptoBlockOpenOptions *ret = NULL; Error *local_err = NULL; ret = g_new0(QCryptoBlockOpenOptions, 1); ret->VAR_0 = VAR_0; ov = opts_visitor_n...
[ "FUNC_0(QCryptoBlockFormat VAR_0,\nQemuOpts *VAR_1,\nError **VAR_2)\n{", "OptsVisitor *ov;", "QCryptoBlockOpenOptions *ret = NULL;", "Error *local_err = NULL;", "ret = g_new0(QCryptoBlockOpenOptions, 1);", "ret->VAR_0 = VAR_0;", "ov = opts_visitor_new(VAR_1);", "visit_start_struct(opts_get_visitor(ov)...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5, 7 ], [ 9 ], [ 11 ], [ 13 ], [ 17 ], [ 19 ], [ 23 ], [ 27, 29 ], [ 31 ], [ 33 ], [ 35 ], [ 39 ], [ 41, 43, 45 ], [ 47 ], [ 51, 53 ], [ 55 ], [ 57 ...
8,189
static void xhci_class_init(ObjectClass *klass, void *data) { PCIDeviceClass *k = PCI_DEVICE_CLASS(klass); DeviceClass *dc = DEVICE_CLASS(klass); dc->vmsd = &vmstate_xhci; dc->props = xhci_properties; dc->reset = xhci_reset; k->init = usb_xhci_initfn; k->vendor_id ...
true
qemu
6c2d1c32d084320081b0cd047f8cacd6e722d03a
static void xhci_class_init(ObjectClass *klass, void *data) { PCIDeviceClass *k = PCI_DEVICE_CLASS(klass); DeviceClass *dc = DEVICE_CLASS(klass); dc->vmsd = &vmstate_xhci; dc->props = xhci_properties; dc->reset = xhci_reset; k->init = usb_xhci_initfn; k->vendor_id ...
{ "code": [], "line_no": [] }
static void FUNC_0(ObjectClass *VAR_0, void *VAR_1) { PCIDeviceClass *k = PCI_DEVICE_CLASS(VAR_0); DeviceClass *dc = DEVICE_CLASS(VAR_0); dc->vmsd = &vmstate_xhci; dc->props = xhci_properties; dc->reset = xhci_reset; k->init = usb_xhci_initfn; k->vendor_id = PCI_V...
[ "static void FUNC_0(ObjectClass *VAR_0, void *VAR_1)\n{", "PCIDeviceClass *k = PCI_DEVICE_CLASS(VAR_0);", "DeviceClass *dc = DEVICE_CLASS(VAR_0);", "dc->vmsd = &vmstate_xhci;", "dc->props = xhci_properties;", "dc->reset = xhci_reset;", "k->init = usb_xhci_initfn;", "k->vendor_id = PC...
[ 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 ], [ 30 ] ]
8,191
static int mxf_read_sequence(MXFSequence *sequence, ByteIOContext *pb, int tag) { switch(tag) { case 0x0202: sequence->duration = get_be64(pb); break; case 0x0201: get_buffer(pb, sequence->data_definition_ul, 16); break; case 0x1001: sequence->structural...
true
FFmpeg
39bb30f6640fe1faf4bbc779a79786028febc95d
static int mxf_read_sequence(MXFSequence *sequence, ByteIOContext *pb, int tag) { switch(tag) { case 0x0202: sequence->duration = get_be64(pb); break; case 0x0201: get_buffer(pb, sequence->data_definition_ul, 16); break; case 0x1001: sequence->structural...
{ "code": [ "static int mxf_read_sequence(MXFSequence *sequence, ByteIOContext *pb, int tag)" ], "line_no": [ 1 ] }
static int FUNC_0(MXFSequence *VAR_0, ByteIOContext *VAR_1, int VAR_2) { switch(VAR_2) { case 0x0202: VAR_0->duration = get_be64(VAR_1); break; case 0x0201: get_buffer(VAR_1, VAR_0->data_definition_ul, 16); break; case 0x1001: VAR_0->structural_component...
[ "static int FUNC_0(MXFSequence *VAR_0, ByteIOContext *VAR_1, int VAR_2)\n{", "switch(VAR_2) {", "case 0x0202:\nVAR_0->duration = get_be64(VAR_1);", "break;", "case 0x0201:\nget_buffer(VAR_1, VAR_0->data_definition_ul, 16);", "break;", "case 0x1001:\nVAR_0->structural_components_count = get_be32(VAR_1);"...
[ 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7, 9 ], [ 11 ], [ 13, 15 ], [ 17 ], [ 19, 21 ], [ 23, 25 ], [ 27 ], [ 29, 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ] ]
8,192
static int common_init(AVCodecContext *avctx){ HYuvContext *s = avctx->priv_data; int i; s->avctx= avctx; s->flags= avctx->flags; dsputil_init(&s->dsp, avctx); s->width= avctx->width; s->height= avctx->height; assert(s->width>0 && s->height>0); for(i=...
true
FFmpeg
ae2f1d4624dc372aa86f85aeb47f820f48a4af38
static int common_init(AVCodecContext *avctx){ HYuvContext *s = avctx->priv_data; int i; s->avctx= avctx; s->flags= avctx->flags; dsputil_init(&s->dsp, avctx); s->width= avctx->width; s->height= avctx->height; assert(s->width>0 && s->height>0); for(i=...
{ "code": [ " int i;", " for(i=0; i<3; i++){", " s->temp[i]= av_malloc(avctx->width + 16);" ], "line_no": [ 5, 27, 29 ] }
static int FUNC_0(AVCodecContext *VAR_0){ HYuvContext *s = VAR_0->priv_data; int VAR_1; s->VAR_0= VAR_0; s->flags= VAR_0->flags; dsputil_init(&s->dsp, VAR_0); s->width= VAR_0->width; s->height= VAR_0->height; assert(s->width>0 && s->height>0); for(VAR...
[ "static int FUNC_0(AVCodecContext *VAR_0){", "HYuvContext *s = VAR_0->priv_data;", "int VAR_1;", "s->VAR_0= VAR_0;", "s->flags= VAR_0->flags;", "dsputil_init(&s->dsp, VAR_0);", "s->width= VAR_0->width;", "s->height= VAR_0->height;", "assert(s->width>0 && s->height>0);", "for(VAR_1=0; VAR_1<3; VAR_...
[ 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0 ]
[ [ 1 ], [ 3 ], [ 5 ], [ 9 ], [ 11 ], [ 15 ], [ 19 ], [ 21 ], [ 23 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ] ]
8,193
static int pic_arrays_init(HEVCContext *s, const HEVCSPS *sps) { int log2_min_cb_size = sps->log2_min_cb_size; int width = sps->width; int height = sps->height; int pic_size_in_ctb = ((width >> log2_min_cb_size) + 1) * ((height >> log2_min_cb_size)...
true
FFmpeg
8aa8d12554868c32436750f881954193087219c8
static int pic_arrays_init(HEVCContext *s, const HEVCSPS *sps) { int log2_min_cb_size = sps->log2_min_cb_size; int width = sps->width; int height = sps->height; int pic_size_in_ctb = ((width >> log2_min_cb_size) + 1) * ((height >> log2_min_cb_size)...
{ "code": [ " s->filter_slice_edges = av_malloc(ctb_count);" ], "line_no": [ 59 ] }
static int FUNC_0(HEVCContext *VAR_0, const HEVCSPS *VAR_1) { int VAR_2 = VAR_1->VAR_2; int VAR_3 = VAR_1->VAR_3; int VAR_4 = VAR_1->VAR_4; int VAR_5 = ((VAR_3 >> VAR_2) + 1) * ((VAR_4 >> VAR_2) + 1); int VAR_6 = VAR_1->ctb_width * VAR_...
[ "static int FUNC_0(HEVCContext *VAR_0, const HEVCSPS *VAR_1)\n{", "int VAR_2 = VAR_1->VAR_2;", "int VAR_3 = VAR_1->VAR_3;", "int VAR_4 = VAR_1->VAR_4;", "int VAR_5 = ((VAR_3 >> VAR_2) + 1) *\n((VAR_4 >> VAR_2) + 1);", "int VAR_6 = VAR_1->ctb_width * VAR_1->ctb_height;", "in...
[ 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 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11, 13 ], [ 15 ], [ 17 ], [ 21 ], [ 23 ], [ 27 ], [ 29 ], [ 31, 33 ], [ 37 ], [ 39 ], [ 41, 43 ], [ 47 ], [ 49 ], [ 51 ], [...
8,194
static int decode_dc_progressive(MJpegDecodeContext *s, int16_t *block, int component, int dc_index, int16_t *quant_matrix, int Al) { int val; s->bdsp.clear_block(block); val = mjpeg_decode_dc(s, dc_index); if (val == 0xfffff) { ...
true
FFmpeg
23f3f92361a3db53e595de33cfd5440f53bee220
static int decode_dc_progressive(MJpegDecodeContext *s, int16_t *block, int component, int dc_index, int16_t *quant_matrix, int Al) { int val; s->bdsp.clear_block(block); val = mjpeg_decode_dc(s, dc_index); if (val == 0xfffff) { ...
{ "code": [ " int16_t *quant_matrix, int Al)" ], "line_no": [ 5 ] }
static int FUNC_0(MJpegDecodeContext *VAR_0, int16_t *VAR_1, int VAR_2, int VAR_3, int16_t *VAR_4, int VAR_5) { int VAR_6; VAR_0->bdsp.clear_block(VAR_1); VAR_6 = mjpeg_decode_dc(VAR_0, VAR_3); if (VAR_6 == 0xfffff) { av_l...
[ "static int FUNC_0(MJpegDecodeContext *VAR_0, int16_t *VAR_1,\nint VAR_2, int VAR_3,\nint16_t *VAR_4, int VAR_5)\n{", "int VAR_6;", "VAR_0->bdsp.clear_block(VAR_1);", "VAR_6 = mjpeg_decode_dc(VAR_0, VAR_3);", "if (VAR_6 == 0xfffff) {", "av_log(VAR_0->avctx, AV_LOG_ERROR, \"error dc\\n\");", "return AVER...
[ 1, 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 ] ]
8,195
static int config_input(AVFilterLink *inlink) { HQDN3DContext *s = inlink->dst->priv; const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(inlink->format); int i; s->hsub = desc->log2_chroma_w; s->vsub = desc->log2_chroma_h; s->depth = desc->comp[0].depth_minus1+1; s->line = av_malloc(inli...
true
FFmpeg
3ba35a346cd2ee86fff83a0d0534e8a2265984fd
static int config_input(AVFilterLink *inlink) { HQDN3DContext *s = inlink->dst->priv; const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(inlink->format); int i; s->hsub = desc->log2_chroma_w; s->vsub = desc->log2_chroma_h; s->depth = desc->comp[0].depth_minus1+1; s->line = av_malloc(inli...
{ "code": [], "line_no": [] }
static int FUNC_0(AVFilterLink *VAR_0) { HQDN3DContext *s = VAR_0->dst->priv; const AVPixFmtDescriptor *VAR_1 = av_pix_fmt_desc_get(VAR_0->format); int VAR_2; s->hsub = VAR_1->log2_chroma_w; s->vsub = VAR_1->log2_chroma_h; s->depth = VAR_1->comp[0].depth_minus1+1; s->line = av_malloc(VAR_0...
[ "static int FUNC_0(AVFilterLink *VAR_0)\n{", "HQDN3DContext *s = VAR_0->dst->priv;", "const AVPixFmtDescriptor *VAR_1 = av_pix_fmt_desc_get(VAR_0->format);", "int VAR_2;", "s->hsub = VAR_1->log2_chroma_w;", "s->vsub = VAR_1->log2_chroma_h;", "s->depth = VAR_1->comp[0].depth_minus1+1;", "s->line = av...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 2 ], [ 3 ], [ 4 ], [ 5 ], [ 6 ], [ 7 ], [ 8 ], [ 9 ], [ 10, 11 ], [ 12 ], [ 13 ], [ 14, 15 ], [ 16 ], [ 17, 18 ], [ 19 ], [ 20 ] ]
8,198
static int64_t mkv_write_cues(AVIOContext *pb, mkv_cues *cues, mkv_track *tracks, int num_tracks) { ebml_master cues_element; int64_t currentpos; int i, j; currentpos = avio_tell(pb); cues_element = start_ebml_master(pb, MATROSKA_ID_CUES, 0); for (i = 0; i < cues->num_entries; i++) { ...
false
FFmpeg
285485ac5f896cc450e0183daa41a8ee63d17076
static int64_t mkv_write_cues(AVIOContext *pb, mkv_cues *cues, mkv_track *tracks, int num_tracks) { ebml_master cues_element; int64_t currentpos; int i, j; currentpos = avio_tell(pb); cues_element = start_ebml_master(pb, MATROSKA_ID_CUES, 0); for (i = 0; i < cues->num_entries; i++) { ...
{ "code": [], "line_no": [] }
static int64_t FUNC_0(AVIOContext *pb, mkv_cues *cues, mkv_track *tracks, int num_tracks) { ebml_master cues_element; int64_t currentpos; int VAR_0, VAR_1; currentpos = avio_tell(pb); cues_element = start_ebml_master(pb, MATROSKA_ID_CUES, 0); for (VAR_0 = 0; VAR_0 < cues->num_entries;...
[ "static int64_t FUNC_0(AVIOContext *pb, mkv_cues *cues, mkv_track *tracks, int num_tracks)\n{", "ebml_master cues_element;", "int64_t currentpos;", "int VAR_0, VAR_1;", "currentpos = avio_tell(pb);", "cues_element = start_ebml_master(pb, MATROSKA_ID_CUES, 0);", "for (VAR_0 = 0; VAR_0 < cues->num_entries...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 13 ], [ 15 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 29 ], [ 31 ], [ 39 ], [ 41 ], [ 43 ], [ 45, 47 ], [ 49 ], [ 51 ], [ 53 ], [...
8,200
static void decode_plane(FFV1Context *s, uint8_t *src, int w, int h, int stride, int plane_index, int pixel_stride) { int x, y; int16_t *sample[2]; sample[0] = s->sample_buffer + 3; sample[1] = s->sample_buffer + w + 6 + 3; s->run_index = 0...
true
FFmpeg
b9f92093a10217b14d923220aaa186f41a0cf555
static void decode_plane(FFV1Context *s, uint8_t *src, int w, int h, int stride, int plane_index, int pixel_stride) { int x, y; int16_t *sample[2]; sample[0] = s->sample_buffer + 3; sample[1] = s->sample_buffer + w + 6 + 3; s->run_index = 0...
{ "code": [ "static void decode_plane(FFV1Context *s, uint8_t *src,", " decode_line(s, w, sample, plane_index, 8);", " decode_line(s, w, sample, plane_index, s->avctx->bits_per_raw_sample);" ], "line_no": [ 1, 49, 57 ] }
static void FUNC_0(FFV1Context *VAR_0, uint8_t *VAR_1, int VAR_2, int VAR_3, int VAR_4, int VAR_5, int VAR_6) { int VAR_7, VAR_8; int16_t *sample[2]; sample[0] = VAR_0->sample_buffer + 3; sample[1] = VAR_0->sample_buffer + VAR_2 + 6 + 3; VA...
[ "static void FUNC_0(FFV1Context *VAR_0, uint8_t *VAR_1,\nint VAR_2, int VAR_3, int VAR_4, int VAR_5,\nint VAR_6)\n{", "int VAR_7, VAR_8;", "int16_t *sample[2];", "sample[0] = VAR_0->sample_buffer + 3;", "sample[1] = VAR_0->sample_buffer + VAR_2 + 6 + 3;", "VAR_0->run_index = 0;", "memset(VAR_0->sample_b...
[ 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5, 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 19 ], [ 23 ], [ 27 ], [ 29 ], [ 33 ], [ 35 ], [ 39 ], [ 41 ], [ 47 ], [ 49 ], [ 51 ], [ 53 ], [ 55 ], [ 57 ...
8,201
void curses_display_init(DisplayState *ds, int full_screen) { #ifndef _WIN32 if (!isatty(1)) { fprintf(stderr, "We need a terminal output\n"); exit(1); } #endif curses_setup(); curses_keyboard_setup(); atexit(curses_atexit); curses_winch_init(); dcl = (Displ...
true
qemu
fedf0d35aafc4f1f1e5f6dbc80cb23ae1ae49f0b
void curses_display_init(DisplayState *ds, int full_screen) { #ifndef _WIN32 if (!isatty(1)) { fprintf(stderr, "We need a terminal output\n"); exit(1); } #endif curses_setup(); curses_keyboard_setup(); atexit(curses_atexit); curses_winch_init(); dcl = (Displ...
{ "code": [ " dcl = (DisplayChangeListener *) g_malloc0(sizeof(DisplayChangeListener));" ], "line_no": [ 31 ] }
void FUNC_0(DisplayState *VAR_0, int VAR_1) { #ifndef _WIN32 if (!isatty(1)) { fprintf(stderr, "We need a terminal output\n"); exit(1); } #endif curses_setup(); curses_keyboard_setup(); atexit(curses_atexit); curses_winch_init(); dcl = (DisplayChangeListener...
[ "void FUNC_0(DisplayState *VAR_0, int VAR_1)\n{", "#ifndef _WIN32\nif (!isatty(1)) {", "fprintf(stderr, \"We need a terminal output\\n\");", "exit(1);", "}", "#endif\ncurses_setup();", "curses_keyboard_setup();", "atexit(curses_atexit);", "curses_winch_init();", "dcl = (DisplayChangeListener *) g_...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5, 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15, 19 ], [ 21 ], [ 23 ], [ 27 ], [ 31 ], [ 33 ], [ 35 ], [ 39 ], [ 41 ] ]
8,202
static int wav_read_header(AVFormatContext *s, AVFormatParameters *ap) { int size; unsigned int tag; ByteIOContext *pb = s->pb; AVStream *st; WAVContext *wav = s->priv_data; /* check RIFF header */ tag = get_le32(pb); if (tag != MKTAG('R', 'I', 'F...
true
FFmpeg
502d6c0a234b10f65acb0a203aedf14de70dc555
static int wav_read_header(AVFormatContext *s, AVFormatParameters *ap) { int size; unsigned int tag; ByteIOContext *pb = s->pb; AVStream *st; WAVContext *wav = s->priv_data; tag = get_le32(pb); if (tag != MKTAG('R', 'I', 'F', 'F')) retur...
{ "code": [ " int size;", " if (size < 0)", " int size;" ], "line_no": [ 7, 43, 7 ] }
static int FUNC_0(AVFormatContext *VAR_0, AVFormatParameters *VAR_1) { int VAR_2; unsigned int VAR_3; ByteIOContext *pb = VAR_0->pb; AVStream *st; WAVContext *wav = VAR_0->priv_data; VAR_3 = get_le32(pb); if (VAR_3 != MKTAG('R', 'I', 'F', 'F')) ...
[ "static int FUNC_0(AVFormatContext *VAR_0,\nAVFormatParameters *VAR_1)\n{", "int VAR_2;", "unsigned int VAR_3;", "ByteIOContext *pb = VAR_0->pb;", "AVStream *st;", "WAVContext *wav = VAR_0->priv_data;", "VAR_3 = get_le32(pb);", "if (VAR_3 != MKTAG('R', 'I', 'F', 'F'))\nreturn -1;", "get_le32(pb);", ...
[ 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 21 ], [ 25, 27 ], [ 29 ], [ 31 ], [ 33, 35 ], [ 41 ], [ 43, 45 ], [ 47 ], [ 49, 51 ], [ 55 ], [ 57 ], [...
8,203
static void add_to_iovec(QEMUFile *f, const uint8_t *buf, int size) { /* check for adjacent buffer and coalesce them */ if (f->iovcnt > 0 && buf == f->iov[f->iovcnt - 1].iov_base + f->iov[f->iovcnt - 1].iov_len) { f->iov[f->iovcnt - 1].iov_len += size; } else { f->iov[f->iovcn...
true
qemu
60fe637bf0e4d7989e21e50f52526444765c63b4
static void add_to_iovec(QEMUFile *f, const uint8_t *buf, int size) { if (f->iovcnt > 0 && buf == f->iov[f->iovcnt - 1].iov_base + f->iov[f->iovcnt - 1].iov_len) { f->iov[f->iovcnt - 1].iov_len += size; } else { f->iov[f->iovcnt].iov_base = (uint8_t *)buf; f->iov[f->...
{ "code": [], "line_no": [] }
static void FUNC_0(QEMUFile *VAR_0, const uint8_t *VAR_1, int VAR_2) { if (VAR_0->iovcnt > 0 && VAR_1 == VAR_0->iov[VAR_0->iovcnt - 1].iov_base + VAR_0->iov[VAR_0->iovcnt - 1].iov_len) { VAR_0->iov[VAR_0->iovcnt - 1].iov_len += VAR_2; } else { VAR_0->iov[VAR_0->iovcnt].iov_ba...
[ "static void FUNC_0(QEMUFile *VAR_0, const uint8_t *VAR_1, int VAR_2)\n{", "if (VAR_0->iovcnt > 0 && VAR_1 == VAR_0->iov[VAR_0->iovcnt - 1].iov_base +\nVAR_0->iov[VAR_0->iovcnt - 1].iov_len) {", "VAR_0->iov[VAR_0->iovcnt - 1].iov_len += VAR_2;", "} else {", "VAR_0->iov[VAR_0->iovcnt].iov_base = (uint8_t *)V...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 7, 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ] ]
8,204
int attribute_align_arg avcodec_decode_video2(AVCodecContext *avctx, AVFrame *picture, int *got_picture_ptr, AVPacket *avpkt) { AVCodecInternal *avci = avctx->internal; int ret; *got_picture_ptr = 0; if ...
true
FFmpeg
a1ee1648690726b34e98eaf8db04fd7b3303cfc8
int attribute_align_arg avcodec_decode_video2(AVCodecContext *avctx, AVFrame *picture, int *got_picture_ptr, AVPacket *avpkt) { AVCodecInternal *avci = avctx->internal; int ret; *got_picture_ptr = 0; if ...
{ "code": [ " if (ret < 0 && picture->buf[0])", " av_frame_unref(picture);" ], "line_no": [ 87, 89 ] }
int VAR_0 avcodec_decode_video2(AVCodecContext *avctx, AVFrame *picture, int *got_picture_ptr, AVPacket *avpkt) { AVCodecInternal *avci = avctx->internal; int ret; *got_picture_ptr = 0; if ((avctx->coded...
[ "int VAR_0 avcodec_decode_video2(AVCodecContext *avctx, AVFrame *picture,\nint *got_picture_ptr,\nAVPacket *avpkt)\n{", "AVCodecInternal *avci = avctx->internal;", "int ret;", "*got_picture_ptr = 0;", "if ((avctx->coded_width || avctx->coded_height) && av_image_check_size(avctx->coded_width, avctx->coded_he...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5, 7 ], [ 9 ], [ 11 ], [ 15 ], [ 17, 19 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31, 33 ], [ 35 ], [ 39 ], [ 43, 45 ], [ 49 ], [ 51, 53, 55 ], [ 57 ], [...
8,205
int av_new_packet(AVPacket *pkt, int size) { uint8_t *data; if((unsigned)size > (unsigned)size + FF_INPUT_BUFFER_PADDING_SIZE) return AVERROR(ENOMEM); data = av_malloc(size + FF_INPUT_BUFFER_PADDING_SIZE); if (!data) return AVERROR(ENOMEM); memset(data + size, 0, FF_INPUT_BUF...
true
FFmpeg
a0b468f5db92daf1854c49d920169ed39e9cfb1b
int av_new_packet(AVPacket *pkt, int size) { uint8_t *data; if((unsigned)size > (unsigned)size + FF_INPUT_BUFFER_PADDING_SIZE) return AVERROR(ENOMEM); data = av_malloc(size + FF_INPUT_BUFFER_PADDING_SIZE); if (!data) return AVERROR(ENOMEM); memset(data + size, 0, FF_INPUT_BUF...
{ "code": [ " uint8_t *data;", " if((unsigned)size > (unsigned)size + FF_INPUT_BUFFER_PADDING_SIZE)", " return AVERROR(ENOMEM);", " if (!data)", " return AVERROR(ENOMEM);" ], "line_no": [ 5, 7, 9, 13, 9 ] }
int FUNC_0(AVPacket *VAR_0, int VAR_1) { uint8_t *data; if((unsigned)VAR_1 > (unsigned)VAR_1 + FF_INPUT_BUFFER_PADDING_SIZE) return AVERROR(ENOMEM); data = av_malloc(VAR_1 + FF_INPUT_BUFFER_PADDING_SIZE); if (!data) return AVERROR(ENOMEM); memset(data + VAR_1, 0, FF_INPUT_BUF...
[ "int FUNC_0(AVPacket *VAR_0, int VAR_1)\n{", "uint8_t *data;", "if((unsigned)VAR_1 > (unsigned)VAR_1 + FF_INPUT_BUFFER_PADDING_SIZE)\nreturn AVERROR(ENOMEM);", "data = av_malloc(VAR_1 + FF_INPUT_BUFFER_PADDING_SIZE);", "if (!data)\nreturn AVERROR(ENOMEM);", "memset(data + VAR_1, 0, FF_INPUT_BUFFER_PADDING...
[ 0, 1, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7, 9 ], [ 11 ], [ 13, 15 ], [ 17 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ] ]
8,206
static int decode_slice(H264Context *h){ MpegEncContext * const s = &h->s; const int part_mask= s->partitioned_frame ? (AC_END|AC_ERROR) : 0x7F; s->mb_skip_run= -1; if( h->pps.cabac ) { int i; /* realign */ align_get_bits( &s->gb ); /* init cabac */ ...
true
FFmpeg
ba17363ff71e68d89b64bc6f129460e9056b9de6
static int decode_slice(H264Context *h){ MpegEncContext * const s = &h->s; const int part_mask= s->partitioned_frame ? (AC_END|AC_ERROR) : 0x7F; s->mb_skip_run= -1; if( h->pps.cabac ) { int i; align_get_bits( &s->gb ); ff_init_cabac_states( &h->...
{ "code": [ " hl_decode_mb(h);" ], "line_no": [ 87 ] }
static int FUNC_0(H264Context *VAR_0){ MpegEncContext * const s = &VAR_0->s; const int VAR_1= s->partitioned_frame ? (AC_END|AC_ERROR) : 0x7F; s->mb_skip_run= -1; if( VAR_0->pps.cabac ) { int VAR_2; align_get_bits( &s->gb ); ff_init_cabac_states...
[ "static int FUNC_0(H264Context *VAR_0){", "MpegEncContext * const s = &VAR_0->s;", "const int VAR_1= s->partitioned_frame ? (AC_END|AC_ERROR) : 0x7F;", "s->mb_skip_run= -1;", "if( VAR_0->pps.cabac ) {", "int VAR_2;", "align_get_bits( &s->gb );", "ff_init_cabac_states( &VAR_0->cabac, ff_h264_lps_range,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ [ 1 ], [ 3 ], [ 5 ], [ 9 ], [ 13 ], [ 15 ], [ 21 ], [ 27 ], [ 29, 31, 33 ], [ 37 ], [ 39 ], [ 41, 43 ], [ 45, 47 ], [ 51, 53 ], [ 55, 57 ], [ 59 ], [ 63 ], ...
8,207
static av_cold int dirac_decode_init(AVCodecContext *avctx) { DiracContext *s = avctx->priv_data; int i; s->avctx = avctx; s->frame_number = -1; if (avctx->flags&CODEC_FLAG_EMU_EDGE) { av_log(avctx, AV_LOG_ERROR, "Edge emulation not supported!\n"); return AVERROR_PATCHWEL...
true
FFmpeg
a91394f4de63ae5c2e21c548045b79393ca7fea1
static av_cold int dirac_decode_init(AVCodecContext *avctx) { DiracContext *s = avctx->priv_data; int i; s->avctx = avctx; s->frame_number = -1; if (avctx->flags&CODEC_FLAG_EMU_EDGE) { av_log(avctx, AV_LOG_ERROR, "Edge emulation not supported!\n"); return AVERROR_PATCHWEL...
{ "code": [ " for (i = 0; i < MAX_FRAMES; i++)" ], "line_no": [ 33 ] }
static av_cold int FUNC_0(AVCodecContext *avctx) { DiracContext *s = avctx->priv_data; int VAR_0; s->avctx = avctx; s->frame_number = -1; if (avctx->flags&CODEC_FLAG_EMU_EDGE) { av_log(avctx, AV_LOG_ERROR, "Edge emulation not supported!\n"); return AVERROR_PATCHWELCOME; ...
[ "static av_cold int FUNC_0(AVCodecContext *avctx)\n{", "DiracContext *s = avctx->priv_data;", "int VAR_0;", "s->avctx = avctx;", "s->frame_number = -1;", "if (avctx->flags&CODEC_FLAG_EMU_EDGE) {", "av_log(avctx, AV_LOG_ERROR, \"Edge emulation not supported!\\n\");", "return AVERROR_PATCHWELCOME;", "...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 11 ], [ 13 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 27 ], [ 29 ], [ 33 ], [ 35 ], [ 39 ], [ 41 ] ]
8,210
static int qemu_chr_open_win_file(HANDLE fd_out, CharDriverState **pchr) { CharDriverState *chr; WinCharState *s; chr = g_malloc0(sizeof(CharDriverState)); s = g_malloc0(sizeof(WinCharState)); s->hcom = fd_out; chr->opaque = s; chr->chr_write = win_chr_write; qemu_chr_generic_...
true
qemu
1f51470d044852592922f91000e741c381582cdc
static int qemu_chr_open_win_file(HANDLE fd_out, CharDriverState **pchr) { CharDriverState *chr; WinCharState *s; chr = g_malloc0(sizeof(CharDriverState)); s = g_malloc0(sizeof(WinCharState)); s->hcom = fd_out; chr->opaque = s; chr->chr_write = win_chr_write; qemu_chr_generic_...
{ "code": [ " return 0;", " return 0;", " return 0;", " return 0;", " return 0;", " return 0;", " return 0;", " return 0;", " return 0;", " return 0;", " return 0;", " return 0;", " return 0;", "static int qemu_chr_open_win...
static int FUNC_0(HANDLE VAR_0, CharDriverState **VAR_1) { CharDriverState *chr; WinCharState *s; chr = g_malloc0(sizeof(CharDriverState)); s = g_malloc0(sizeof(WinCharState)); s->hcom = VAR_0; chr->opaque = s; chr->chr_write = win_chr_write; qemu_chr_generic_open(chr); *...
[ "static int FUNC_0(HANDLE VAR_0, CharDriverState **VAR_1)\n{", "CharDriverState *chr;", "WinCharState *s;", "chr = g_malloc0(sizeof(CharDriverState));", "s = g_malloc0(sizeof(WinCharState));", "s->hcom = VAR_0;", "chr->opaque = s;", "chr->chr_write = win_chr_write;", "qemu_chr_generic_open(chr);", ...
[ 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ] ]
8,212
int qcrypto_cipher_encrypt(QCryptoCipher *cipher, const void *in, void *out, size_t len, Error **errp) { QCryptoCipherNettle *ctx = cipher->opaque; switch (cipher->mode) { case QCRYPTO_CIPHE...
true
qemu
3a661f1eabf7e8db66e28489884d9b54aacb94ea
int qcrypto_cipher_encrypt(QCryptoCipher *cipher, const void *in, void *out, size_t len, Error **errp) { QCryptoCipherNettle *ctx = cipher->opaque; switch (cipher->mode) { case QCRYPTO_CIPHE...
{ "code": [ " ctx->niv, ctx->iv," ], "line_no": [ 31 ] }
int FUNC_0(QCryptoCipher *VAR_0, const void *VAR_1, void *VAR_2, size_t VAR_3, Error **VAR_4) { QCryptoCipherNettle *ctx = VAR_0->opaque; switch (VAR_0->mode) { case QCRYPTO_CIPHER_MODE_ECB:...
[ "int FUNC_0(QCryptoCipher *VAR_0,\nconst void *VAR_1,\nvoid *VAR_2,\nsize_t VAR_3,\nError **VAR_4)\n{", "QCryptoCipherNettle *ctx = VAR_0->opaque;", "switch (VAR_0->mode) {", "case QCRYPTO_CIPHER_MODE_ECB:\nctx->alg_encrypt(ctx->ctx_encrypt, VAR_3, VAR_2, VAR_1);", "break;", "case QCRYPTO_CIPHER_MODE_CBC:...
[ 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5, 7, 9, 11 ], [ 13 ], [ 17 ], [ 19, 21 ], [ 23 ], [ 27, 29, 31, 33 ], [ 35 ], [ 37, 39, 41 ], [ 43 ], [ 45 ], [ 47 ], [ 49 ] ]
8,213
static int color_distance(uint32_t a, uint32_t b) { int r = 0, d, i; for (i = 0; i < 32; i += 8) { d = ((a >> i) & 0xFF) - ((b >> i) & 0xFF); r += d * d; } return r; }
true
FFmpeg
5ed5e90f2ae299cbec66996860d794771a85fee8
static int color_distance(uint32_t a, uint32_t b) { int r = 0, d, i; for (i = 0; i < 32; i += 8) { d = ((a >> i) & 0xFF) - ((b >> i) & 0xFF); r += d * d; } return r; }
{ "code": [ " for (i = 0; i < 32; i += 8) {", " d = ((a >> i) & 0xFF) - ((b >> i) & 0xFF);" ], "line_no": [ 9, 11 ] }
static int FUNC_0(uint32_t VAR_0, uint32_t VAR_1) { int VAR_2 = 0, VAR_3, VAR_4; for (VAR_4 = 0; VAR_4 < 32; VAR_4 += 8) { VAR_3 = ((VAR_0 >> VAR_4) & 0xFF) - ((VAR_1 >> VAR_4) & 0xFF); VAR_2 += VAR_3 * VAR_3; } return VAR_2; }
[ "static int FUNC_0(uint32_t VAR_0, uint32_t VAR_1)\n{", "int VAR_2 = 0, VAR_3, VAR_4;", "for (VAR_4 = 0; VAR_4 < 32; VAR_4 += 8) {", "VAR_3 = ((VAR_0 >> VAR_4) & 0xFF) - ((VAR_1 >> VAR_4) & 0xFF);", "VAR_2 += VAR_3 * VAR_3;", "}", "return VAR_2;", "}" ]
[ 0, 0, 1, 1, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ] ]
8,214
static int32_t scsi_send_command(SCSIDevice *d, uint32_t tag, uint8_t *cmd, int lun) { SCSIGenericState *s = DO_UPCAST(SCSIGenericState, qdev, d); SCSIGenericReq *r; SCSIBus *bus; int ret; if (cmd[0] != REQUEST_SENSE && (lun != s->lun || (cmd[1] >> ...
true
qemu
ad2d30f79d3b0812f02c741be2189796b788d6d7
static int32_t scsi_send_command(SCSIDevice *d, uint32_t tag, uint8_t *cmd, int lun) { SCSIGenericState *s = DO_UPCAST(SCSIGenericState, qdev, d); SCSIGenericReq *r; SCSIBus *bus; int ret; if (cmd[0] != REQUEST_SENSE && (lun != s->lun || (cmd[1] >> ...
{ "code": [ " scsi_remove_request(r);", " scsi_remove_request(r);", " scsi_remove_request(r);", " scsi_remove_request(r);", " return -r->req.cmd.xfer;", " return r->req.cmd.xfer;", " scsi_remove_request(r);" ], "line_no": [ 71, 71, ...
static int32_t FUNC_0(SCSIDevice *d, uint32_t tag, uint8_t *cmd, int lun) { SCSIGenericState *s = DO_UPCAST(SCSIGenericState, qdev, d); SCSIGenericReq *r; SCSIBus *bus; int VAR_0; if (cmd[0] != REQUEST_SENSE && (lun != s->lun || (cmd[1] >> 5) != s->...
[ "static int32_t FUNC_0(SCSIDevice *d, uint32_t tag,\nuint8_t *cmd, int lun)\n{", "SCSIGenericState *s = DO_UPCAST(SCSIGenericState, qdev, d);", "SCSIGenericReq *r;", "SCSIBus *bus;", "int VAR_0;", "if (cmd[0] != REQUEST_SENSE &&\n(lun != s->lun || (cmd[1] >> 5) != s->lun)) {", "DPRINTF(\"Unimplemented 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, 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, 0, 1, 0...
[ [ 1, 3, 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 17, 19 ], [ 21 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ...
8,215
static void gen_mfsr_64b(DisasContext *ctx) { #if defined(CONFIG_USER_ONLY) gen_inval_exception(ctx, POWERPC_EXCP_PRIV_REG); #else TCGv t0; if (unlikely(ctx->pr)) { gen_inval_exception(ctx, POWERPC_EXCP_PRIV_REG); return; } t0 = tcg_const_tl(SR(ctx->opcode)); gen_helpe...
true
qemu
9b2fadda3e0196ffd485adde4fe9cdd6fae35300
static void gen_mfsr_64b(DisasContext *ctx) { #if defined(CONFIG_USER_ONLY) gen_inval_exception(ctx, POWERPC_EXCP_PRIV_REG); #else TCGv t0; if (unlikely(ctx->pr)) { gen_inval_exception(ctx, POWERPC_EXCP_PRIV_REG); return; } t0 = tcg_const_tl(SR(ctx->opcode)); gen_helpe...
{ "code": [ " if (unlikely(ctx->pr)) {", " if (unlikely(ctx->pr)) {", "#if defined(CONFIG_USER_ONLY)", " gen_inval_exception(ctx, POWERPC_EXCP_PRIV_REG);", "#else", " if (unlikely(ctx->pr)) {", " gen_inval_exception(ctx, POWERPC_EXCP_PRIV_REG);", "#endif", "#if d...
static void FUNC_0(DisasContext *VAR_0) { #if defined(CONFIG_USER_ONLY) gen_inval_exception(VAR_0, POWERPC_EXCP_PRIV_REG); #else TCGv t0; if (unlikely(VAR_0->pr)) { gen_inval_exception(VAR_0, POWERPC_EXCP_PRIV_REG); return; } t0 = tcg_const_tl(SR(VAR_0->opcode)); gen_h...
[ "static void FUNC_0(DisasContext *VAR_0)\n{", "#if defined(CONFIG_USER_ONLY)\ngen_inval_exception(VAR_0, POWERPC_EXCP_PRIV_REG);", "#else\nTCGv t0;", "if (unlikely(VAR_0->pr)) {", "gen_inval_exception(VAR_0, POWERPC_EXCP_PRIV_REG);", "return;", "}", "t0 = tcg_const_tl(SR(VAR_0->opcode));", "gen_help...
[ 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1 ]
[ [ 1, 3 ], [ 5, 7 ], [ 9, 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27, 29 ] ]
8,216
struct omap_gpmc_s *omap_gpmc_init(target_phys_addr_t base, qemu_irq irq) { struct omap_gpmc_s *s = (struct omap_gpmc_s *) g_malloc0(sizeof(struct omap_gpmc_s)); memory_region_init_io(&s->iomem, &omap_gpmc_ops, s, "omap-gpmc", 0x1000); memory_region_add_subregion(get_system_memory(), base...
true
qemu
77c6c7369035c25d9d4babd920dbe691e3453cfc
struct omap_gpmc_s *omap_gpmc_init(target_phys_addr_t base, qemu_irq irq) { struct omap_gpmc_s *s = (struct omap_gpmc_s *) g_malloc0(sizeof(struct omap_gpmc_s)); memory_region_init_io(&s->iomem, &omap_gpmc_ops, s, "omap-gpmc", 0x1000); memory_region_add_subregion(get_system_memory(), base...
{ "code": [], "line_no": [] }
struct omap_gpmc_s *FUNC_0(target_phys_addr_t VAR_0, qemu_irq VAR_1) { struct omap_gpmc_s *VAR_2 = (struct omap_gpmc_s *) g_malloc0(sizeof(struct omap_gpmc_s)); memory_region_init_io(&VAR_2->iomem, &omap_gpmc_ops, VAR_2, "omap-gpmc", 0x1000); memory_region_add_subregion(get_system_memory(...
[ "struct omap_gpmc_s *FUNC_0(target_phys_addr_t VAR_0, qemu_irq VAR_1)\n{", "struct omap_gpmc_s *VAR_2 = (struct omap_gpmc_s *)\ng_malloc0(sizeof(struct omap_gpmc_s));", "memory_region_init_io(&VAR_2->iomem, &omap_gpmc_ops, VAR_2, \"omap-gpmc\", 0x1000);", "memory_region_add_subregion(get_system_memory(), VAR_...
[ 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5, 7 ], [ 11 ], [ 13 ], [ 18 ], [ 22 ], [ 24 ] ]
8,219
static void sbr_qmf_deint_bfly_c(INTFLOAT *v, const INTFLOAT *src0, const INTFLOAT *src1) { int i; for (i = 0; i < 64; i++) { v[ i] = AAC_SRA_R((src0[i] - src1[63 - i]), 5); v[127 - i] = AAC_SRA_R((src0[i] + src1[63 - i]), 5); } }
true
FFmpeg
7c36ee216f1e668e2c2af1573bd9dbbb2a501f48
static void sbr_qmf_deint_bfly_c(INTFLOAT *v, const INTFLOAT *src0, const INTFLOAT *src1) { int i; for (i = 0; i < 64; i++) { v[ i] = AAC_SRA_R((src0[i] - src1[63 - i]), 5); v[127 - i] = AAC_SRA_R((src0[i] + src1[63 - i]), 5); } }
{ "code": [ " v[ i] = AAC_SRA_R((src0[i] - src1[63 - i]), 5);", " v[127 - i] = AAC_SRA_R((src0[i] + src1[63 - i]), 5);" ], "line_no": [ 9, 11 ] }
static void FUNC_0(INTFLOAT *VAR_0, const INTFLOAT *VAR_1, const INTFLOAT *VAR_2) { int VAR_3; for (VAR_3 = 0; VAR_3 < 64; VAR_3++) { VAR_0[ VAR_3] = AAC_SRA_R((VAR_1[VAR_3] - VAR_2[63 - VAR_3]), 5); VAR_0[127 - VAR_3] = AAC_SRA_R((VAR_1[VAR_3] + VAR_2[63 - VAR_3]), 5); } }
[ "static void FUNC_0(INTFLOAT *VAR_0, const INTFLOAT *VAR_1, const INTFLOAT *VAR_2)\n{", "int VAR_3;", "for (VAR_3 = 0; VAR_3 < 64; VAR_3++) {", "VAR_0[ VAR_3] = AAC_SRA_R((VAR_1[VAR_3] - VAR_2[63 - VAR_3]), 5);", "VAR_0[127 - VAR_3] = AAC_SRA_R((VAR_1[VAR_3] + VAR_2[63 - VAR_3]), 5);", "}", "}" ]
[ 0, 0, 0, 1, 1, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ] ]
8,220
static void gif_copy_img_rect(const uint32_t *src, uint32_t *dst, int linesize, int l, int t, int w, int h) { const int y_start = t * linesize; const uint32_t *src_px, *src_pr, *src_py = src + y_start, *dst_py = dst + y_start; const ...
true
FFmpeg
9321e93502810e4a3fcaf87bac156dba2fe3b477
static void gif_copy_img_rect(const uint32_t *src, uint32_t *dst, int linesize, int l, int t, int w, int h) { const int y_start = t * linesize; const uint32_t *src_px, *src_pr, *src_py = src + y_start, *dst_py = dst + y_start; const ...
{ "code": [ " const uint32_t *src_pb = src_py + (t + h) * linesize;" ], "line_no": [ 15 ] }
static void FUNC_0(const uint32_t *VAR_0, uint32_t *VAR_1, int VAR_2, int VAR_3, int VAR_4, int VAR_5, int VAR_6) { const int VAR_7 = VAR_4 * VAR_2; const uint32_t *VAR_8, *src_pr, *src_py = VAR_0 + VAR_7, *dst_py = VAR_1 + VAR_7; co...
[ "static void FUNC_0(const uint32_t *VAR_0, uint32_t *VAR_1,\nint VAR_2, int VAR_3, int VAR_4, int VAR_5, int VAR_6)\n{", "const int VAR_7 = VAR_4 * VAR_2;", "const uint32_t *VAR_8, *src_pr,\n*src_py = VAR_0 + VAR_7,\n*dst_py = VAR_1 + VAR_7;", "const uint32_t *VAR_9 = src_py + (VAR_4 + VAR_6) * VAR_2;", "ui...
[ 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5 ], [ 7 ], [ 9, 11, 13 ], [ 15 ], [ 17 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ] ]
8,222
void OPPROTO op_divd (void) { if (unlikely(((int64_t)T0 == INT64_MIN && (int64_t)T1 == -1) || (int64_t)T1 == 0)) { T0 = (int64_t)((-1ULL) * ((uint64_t)T0 >> 63)); } else { T0 = (int64_t)T0 / (int64_t)T1; } RETURN(); }
true
qemu
6f2d8978728c48ca46f5c01835438508aace5c64
void OPPROTO op_divd (void) { if (unlikely(((int64_t)T0 == INT64_MIN && (int64_t)T1 == -1) || (int64_t)T1 == 0)) { T0 = (int64_t)((-1ULL) * ((uint64_t)T0 >> 63)); } else { T0 = (int64_t)T0 / (int64_t)T1; } RETURN(); }
{ "code": [ " if (unlikely(((int64_t)T0 == INT64_MIN && (int64_t)T1 == -1) ||", " T0 = (int64_t)((-1ULL) * ((uint64_t)T0 >> 63));" ], "line_no": [ 5, 9 ] }
void VAR_0 op_divd (void) { if (unlikely(((int64_t)T0 == INT64_MIN && (int64_t)T1 == -1) || (int64_t)T1 == 0)) { T0 = (int64_t)((-1ULL) * ((uint64_t)T0 >> 63)); } else { T0 = (int64_t)T0 / (int64_t)T1; } RETURN(); }
[ "void VAR_0 op_divd (void)\n{", "if (unlikely(((int64_t)T0 == INT64_MIN && (int64_t)T1 == -1) ||\n(int64_t)T1 == 0)) {", "T0 = (int64_t)((-1ULL) * ((uint64_t)T0 >> 63));", "} else {", "T0 = (int64_t)T0 / (int64_t)T1;", "}", "RETURN();", "}" ]
[ 0, 1, 1, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5, 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ] ]
8,223
static uint64_t cg3_reg_read(void *opaque, hwaddr addr, unsigned size) { CG3State *s = opaque; int val; switch (addr) { case CG3_REG_BT458_ADDR: case CG3_REG_BT458_COLMAP: val = 0; break; case CG3_REG_FBC_CTRL: val = s->regs[0]; break; case CG3_R...
true
qemu
366d4f7e0007a5540897fbac6e377c57d8c79a73
static uint64_t cg3_reg_read(void *opaque, hwaddr addr, unsigned size) { CG3State *s = opaque; int val; switch (addr) { case CG3_REG_BT458_ADDR: case CG3_REG_BT458_COLMAP: val = 0; break; case CG3_REG_FBC_CTRL: val = s->regs[0]; break; case CG3_R...
{ "code": [ " case CG3_REG_FBC_CURSTART ... CG3_REG_SIZE:", " case CG3_REG_FBC_CURSTART ... CG3_REG_SIZE:" ], "line_no": [ 35, 35 ] }
static uint64_t FUNC_0(void *opaque, hwaddr addr, unsigned size) { CG3State *s = opaque; int VAR_0; switch (addr) { case CG3_REG_BT458_ADDR: case CG3_REG_BT458_COLMAP: VAR_0 = 0; break; case CG3_REG_FBC_CTRL: VAR_0 = s->regs[0]; break; case CG3_R...
[ "static uint64_t FUNC_0(void *opaque, hwaddr addr, unsigned size)\n{", "CG3State *s = opaque;", "int VAR_0;", "switch (addr) {", "case CG3_REG_BT458_ADDR:\ncase CG3_REG_BT458_COLMAP:\nVAR_0 = 0;", "break;", "case CG3_REG_FBC_CTRL:\nVAR_0 = s->regs[0];", "break;", "case CG3_REG_FBC_STATUS:\nVAR_0 = s...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 11 ], [ 13, 15, 17 ], [ 19 ], [ 21, 23 ], [ 25 ], [ 27, 31 ], [ 33 ], [ 35, 37 ], [ 39 ], [ 41, 43, 45, 47, 49 ], [ 51 ], [ 53 ], ...
8,224
static int expand_rle_row(SgiState *s, uint8_t *out_buf, uint8_t *out_end, int pixelstride) { unsigned char pixel, count; unsigned char *orig = out_buf; while (1) { if (bytestream2_get_bytes_left(&s->g) < 1) return AVERROR_INVALIDDATA; pixel = ...
true
FFmpeg
7bc155163ec08a0302526d7e19d08c8053f932f0
static int expand_rle_row(SgiState *s, uint8_t *out_buf, uint8_t *out_end, int pixelstride) { unsigned char pixel, count; unsigned char *orig = out_buf; while (1) { if (bytestream2_get_bytes_left(&s->g) < 1) return AVERROR_INVALIDDATA; pixel = ...
{ "code": [ " if(out_buf + pixelstride * count >= out_end) return -1;" ], "line_no": [ 31 ] }
static int FUNC_0(SgiState *VAR_0, uint8_t *VAR_1, uint8_t *VAR_2, int VAR_3) { unsigned char VAR_4, VAR_5; unsigned char *VAR_6 = VAR_1; while (1) { if (bytestream2_get_bytes_left(&VAR_0->g) < 1) return AVERROR_INVALIDDATA; VAR_4 = bytestream2...
[ "static int FUNC_0(SgiState *VAR_0, uint8_t *VAR_1,\nuint8_t *VAR_2, int VAR_3)\n{", "unsigned char VAR_4, VAR_5;", "unsigned char *VAR_6 = VAR_1;", "while (1) {", "if (bytestream2_get_bytes_left(&VAR_0->g) < 1)\nreturn AVERROR_INVALIDDATA;", "VAR_4 = bytestream2_get_byteu(&VAR_0->g);", "if (!(VAR_5 = (...
[ 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 ], [ 13 ], [ 15, 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 31 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ], [ 51 ], [ 53 ...
8,225
static void new_connection(int server_fd, int is_rtsp) { struct sockaddr_in from_addr; int fd, len; HTTPContext *c = NULL; len = sizeof(from_addr); fd = accept(server_fd, (struct sockaddr *)&from_addr, &len); if (fd < 0) return; fcntl(fd, F_SETFL, O_NONBL...
true
FFmpeg
8bc80f8b24cb6f03ad209ce546ae594904c8b353
static void new_connection(int server_fd, int is_rtsp) { struct sockaddr_in from_addr; int fd, len; HTTPContext *c = NULL; len = sizeof(from_addr); fd = accept(server_fd, (struct sockaddr *)&from_addr, &len); if (fd < 0) return; fcntl(fd, F_SETFL, O_NONBL...
{ "code": [ " c->next = first_http_ctx;", " first_http_ctx = c;" ], "line_no": [ 47, 49 ] }
static void FUNC_0(int VAR_0, int VAR_1) { struct sockaddr_in VAR_2; int VAR_3, VAR_4; HTTPContext *c = NULL; VAR_4 = sizeof(VAR_2); VAR_3 = accept(VAR_0, (struct sockaddr *)&VAR_2, &VAR_4); if (VAR_3 < 0) return; fcntl(VAR_3, F_SETFL, O_NONBLOCK); ...
[ "static void FUNC_0(int VAR_0, int VAR_1)\n{", "struct sockaddr_in VAR_2;", "int VAR_3, VAR_4;", "HTTPContext *c = NULL;", "VAR_4 = sizeof(VAR_2);", "VAR_3 = accept(VAR_0, (struct sockaddr *)&VAR_2,\n&VAR_4);", "if (VAR_3 < 0)\nreturn;", "fcntl(VAR_3, F_SETFL, O_NONBLOCK);", "if (nb_connections >= n...
[ 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 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 13 ], [ 15, 17 ], [ 19, 21 ], [ 23 ], [ 31, 33 ], [ 39 ], [ 41, 43 ], [ 47 ], [ 49 ], [ 51 ], [ 53 ], [ 55 ], [ 57 ], [ 59 ...
8,227
static void apply_independent_coupling_fixed(AACContext *ac, SingleChannelElement *target, ChannelElement *cce, int index) { int i, c, shift, round, tmp; const int gain = cce->coup.gain[index][0]; const int *src = cce->ch[0]...
true
FFmpeg
620b452a118a6a2345addb4e1d8abf36ad8d1bab
static void apply_independent_coupling_fixed(AACContext *ac, SingleChannelElement *target, ChannelElement *cce, int index) { int i, c, shift, round, tmp; const int gain = cce->coup.gain[index][0]; const int *src = cce->ch[0]...
{ "code": [ " if (shift < 0) {" ], "line_no": [ 25 ] }
static void FUNC_0(AACContext *VAR_0, SingleChannelElement *VAR_1, ChannelElement *VAR_2, int VAR_3) { int VAR_4, VAR_5, VAR_6, VAR_7, VAR_8; const int VAR_9 = VAR_2->coup.VAR_9[VAR_3][0]; const int *VAR_10 = VAR_2->ch[0].re...
[ "static void FUNC_0(AACContext *VAR_0,\nSingleChannelElement *VAR_1,\nChannelElement *VAR_2, int VAR_3)\n{", "int VAR_4, VAR_5, VAR_6, VAR_7, VAR_8;", "const int VAR_9 = VAR_2->coup.VAR_9[VAR_3][0];", "const int *VAR_10 = VAR_2->ch[0].ret;", "int *VAR_11 = VAR_1->ret;", "const int VAR_12 = 1024 << (VAR_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 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ...
8,228
int kvm_arch_get_registers(CPUState *cs) { PowerPCCPU *cpu = POWERPC_CPU(cs); CPUPPCState *env = &cpu->env; struct kvm_regs regs; struct kvm_sregs sregs; uint32_t cr; int i, ret; ret = kvm_vcpu_ioctl(cs, KVM_GET_REGS, &regs); if (ret < 0) return ret; cr = regs....
true
qemu
f3c75d42adbba553eaf218a832d4fbea32c8f7b8
int kvm_arch_get_registers(CPUState *cs) { PowerPCCPU *cpu = POWERPC_CPU(cs); CPUPPCState *env = &cpu->env; struct kvm_regs regs; struct kvm_sregs sregs; uint32_t cr; int i, ret; ret = kvm_vcpu_ioctl(cs, KVM_GET_REGS, &regs); if (ret < 0) return ret; cr = regs....
{ "code": [ " ppc_store_sdr1(env, sregs.u.s.sdr1);" ], "line_no": [ 309 ] }
int FUNC_0(CPUState *VAR_0) { PowerPCCPU *cpu = POWERPC_CPU(VAR_0); CPUPPCState *env = &cpu->env; struct kvm_regs VAR_1; struct kvm_sregs VAR_2; uint32_t cr; int VAR_5, VAR_4; VAR_4 = kvm_vcpu_ioctl(VAR_0, KVM_GET_REGS, &VAR_1); if (VAR_4 < 0) return VAR_4; cr ...
[ "int FUNC_0(CPUState *VAR_0)\n{", "PowerPCCPU *cpu = POWERPC_CPU(VAR_0);", "CPUPPCState *env = &cpu->env;", "struct kvm_regs VAR_1;", "struct kvm_sregs VAR_2;", "uint32_t cr;", "int VAR_5, VAR_4;", "VAR_4 = kvm_vcpu_ioctl(VAR_0, KVM_GET_REGS, &VAR_1);", "if (VAR_4 < 0)\nreturn VAR_4;", "cr = 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 ], [ 19 ], [ 21, 23 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ], [...
8,229
static int mov_read_tkhd(MOVContext *c, AVIOContext *pb, MOVAtom atom) { int i; int width; int height; int display_matrix[3][3]; AVStream *st; MOVStreamContext *sc; int version; int flags; if (c->fc->nb_streams < 1) return 0; st = c->fc->streams[c->fc->nb_st...
true
FFmpeg
e32b07aea4981719a3e6ce92491349c9547958e1
static int mov_read_tkhd(MOVContext *c, AVIOContext *pb, MOVAtom atom) { int i; int width; int height; int display_matrix[3][3]; AVStream *st; MOVStreamContext *sc; int version; int flags; if (c->fc->nb_streams < 1) return 0; st = c->fc->streams[c->fc->nb_st...
{ "code": [ " if (disp_transform[0] > 0 && disp_transform[1] > 0 &&" ], "line_no": [ 191 ] }
static int FUNC_0(MOVContext *VAR_0, AVIOContext *VAR_1, MOVAtom VAR_2) { int VAR_9; int VAR_4; int VAR_5; int VAR_6[3][3]; AVStream *st; MOVStreamContext *sc; int VAR_7; int VAR_8; if (VAR_0->fc->nb_streams < 1) return 0; st = VAR_0->fc->streams[VAR_0->fc->...
[ "static int FUNC_0(MOVContext *VAR_0, AVIOContext *VAR_1, MOVAtom VAR_2)\n{", "int VAR_9;", "int VAR_4;", "int VAR_5;", "int VAR_6[3][3];", "AVStream *st;", "MOVStreamContext *sc;", "int VAR_7;", "int VAR_8;", "if (VAR_0->fc->nb_streams < 1)\nreturn 0;", "st = VAR_0->fc->streams[VAR_0->fc->nb_st...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0...
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 23, 25 ], [ 27 ], [ 29 ], [ 33 ], [ 35 ], [ 37 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ], [...
8,230
int ff_mjpeg_find_marker(MJpegDecodeContext *s, const uint8_t **buf_ptr, const uint8_t *buf_end, const uint8_t **unescaped_buf_ptr, int *unescaped_buf_size) { int start_code; start_code = find_marker(buf_ptr, buf_end); av_fa...
true
FFmpeg
509c9e74e548139285f30ed8dcc9baf1d64359fa
int ff_mjpeg_find_marker(MJpegDecodeContext *s, const uint8_t **buf_ptr, const uint8_t *buf_end, const uint8_t **unescaped_buf_ptr, int *unescaped_buf_size) { int start_code; start_code = find_marker(buf_ptr, buf_end); av_fa...
{ "code": [ " if (x == 0xFF) {" ], "line_no": [ 133 ] }
int FUNC_0(MJpegDecodeContext *VAR_0, const uint8_t **VAR_1, const uint8_t *VAR_2, const uint8_t **VAR_3, int *VAR_4) { int VAR_5; VAR_5 = find_marker(VAR_1, VAR_2); av_fast_padded_malloc(&VAR_0->buffer, &VAR_0->buffer_size,...
[ "int FUNC_0(MJpegDecodeContext *VAR_0,\nconst uint8_t **VAR_1, const uint8_t *VAR_2,\nconst uint8_t **VAR_3,\nint *VAR_4)\n{", "int VAR_5;", "VAR_5 = find_marker(VAR_1, VAR_2);", "av_fast_padded_malloc(&VAR_0->buffer, &VAR_0->buffer_size, VAR_2 - *VAR_1);", "if (!VAR_0->buffer)\nreturn AVERROR(ENOMEM);", ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ [ 1, 3, 5, 7, 9 ], [ 11 ], [ 13 ], [ 17 ], [ 19, 21 ], [ 27 ], [ 29 ], [ 31 ], [ 35 ], [ 37 ], [ 41 ], [ 43 ], [ 45 ], [ 47, 49 ], [ 53, 55 ], [ 57, 59 ], [...
8,231
static void rc4030_dma_tt_write(void *opaque, hwaddr addr, uint64_t data, unsigned int size) { rc4030State *s = opaque; /* write memory */ memcpy(memory_region_get_ram_ptr(&s->dma_tt) + addr, &data, size); /* update dma address space (only if frame field has bee...
true
qemu
c627e7526a902dd5bb1907dbbd5cf961679dfa68
static void rc4030_dma_tt_write(void *opaque, hwaddr addr, uint64_t data, unsigned int size) { rc4030State *s = opaque; memcpy(memory_region_get_ram_ptr(&s->dma_tt) + addr, &data, size); if (addr % sizeof(dma_pagetable_entry) == 0) { int index = ...
{ "code": [ "static void rc4030_dma_tt_write(void *opaque, hwaddr addr, uint64_t data,", " unsigned int size)", " rc4030State *s = opaque;", " memcpy(memory_region_get_ram_ptr(&s->dma_tt) + addr, &data, size);", " if (addr % sizeof(dma_pagetable_entry) == 0)...
static void FUNC_0(void *VAR_0, hwaddr VAR_1, uint64_t VAR_2, unsigned int VAR_3) { rc4030State *s = VAR_0; memcpy(memory_region_get_ram_ptr(&s->dma_tt) + VAR_1, &VAR_2, VAR_3); if (VAR_1 % sizeof(dma_pagetable_entry) == 0) { int VAR_4 = VAR_1 / ...
[ "static void FUNC_0(void *VAR_0, hwaddr VAR_1, uint64_t VAR_2,\nunsigned int VAR_3)\n{", "rc4030State *s = VAR_0;", "memcpy(memory_region_get_ram_ptr(&s->dma_tt) + VAR_1, &VAR_2, VAR_3);", "if (VAR_1 % sizeof(dma_pagetable_entry) == 0) {", "int VAR_4 = VAR_1 / sizeof(dma_pagetable_entry);", "memory_region...
[ 1, 1, 1, 1, 1, 1, 1, 1, 0, 0 ]
[ [ 1, 3, 5 ], [ 7 ], [ 13 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ] ]