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
6,084
static void memory_region_iorange_write(IORange *iorange, uint64_t offset, unsigned width, uint64_t data) { MemoryRegionIORange *mrio = container_of(iorange, MemoryRegionIORange, ior...
false
qemu
b40acf99bef69fa8ab0f9092ff162fde945eec12
static void memory_region_iorange_write(IORange *iorange, uint64_t offset, unsigned width, uint64_t data) { MemoryRegionIORange *mrio = container_of(iorange, MemoryRegionIORange, ior...
{ "code": [], "line_no": [] }
static void FUNC_0(IORange *VAR_0, uint64_t VAR_1, unsigned VAR_2, uint64_t VAR_3) { MemoryRegionIORange *mrio = container_of(VAR_0, MemoryRegionIORange, VAR_0); MemoryRegion *m...
[ "static void FUNC_0(IORange *VAR_0,\nuint64_t VAR_1,\nunsigned VAR_2,\nuint64_t VAR_3)\n{", "MemoryRegionIORange *mrio\n= container_of(VAR_0, MemoryRegionIORange, VAR_0);", "MemoryRegion *mr = mrio->mr;", "VAR_1 += mrio->VAR_1;", "if (mr->ops->old_portio) {", "const MemoryRegionPortio *VAR_4 = find_portio...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5, 7, 9 ], [ 11, 13 ], [ 15 ], [ 19 ], [ 21 ], [ 23, 25 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ], [ 49, 51,...
6,085
int msi_init(struct PCIDevice *dev, uint8_t offset, unsigned int nr_vectors, bool msi64bit, bool msi_per_vector_mask) { unsigned int vectors_order; uint16_t flags; uint8_t cap_size; int config_offset; if (!msi_supported) { return -ENOTSUP; } MSI_DEV_PRINTF(...
false
qemu
786a4ea82ec9c87e3a895cf41081029b285a5fe5
int msi_init(struct PCIDevice *dev, uint8_t offset, unsigned int nr_vectors, bool msi64bit, bool msi_per_vector_mask) { unsigned int vectors_order; uint16_t flags; uint8_t cap_size; int config_offset; if (!msi_supported) { return -ENOTSUP; } MSI_DEV_PRINTF(...
{ "code": [], "line_no": [] }
int FUNC_0(struct PCIDevice *VAR_0, uint8_t VAR_1, unsigned int VAR_2, bool VAR_3, bool VAR_4) { unsigned int VAR_5; uint16_t flags; uint8_t cap_size; int VAR_6; if (!msi_supported) { return -ENOTSUP; } MSI_DEV_PRINTF(VAR_0, "init VAR_1:...
[ "int FUNC_0(struct PCIDevice *VAR_0, uint8_t VAR_1,\nunsigned int VAR_2, bool VAR_3, bool VAR_4)\n{", "unsigned int VAR_5;", "uint16_t flags;", "uint8_t cap_size;", "int VAR_6;", "if (!msi_supported) {", "return -ENOTSUP;", "}", "MSI_DEV_PRINTF(VAR_0,\n\"init VAR_1: 0x%\"PRIx8\" vector: %\"PRId8\n\"...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 17 ], [ 19 ], [ 21 ], [ 25, 27, 29, 31 ], [ 35 ], [ 37 ], [ 39 ], [ 43 ], [ 47 ], [ 49 ], [ 51 ], [ 53 ], [ 55 ...
6,086
static int mux_chr_write(CharDriverState *chr, const uint8_t *buf, int len) { MuxDriver *d = chr->opaque; int ret; if (!d->timestamps) { ret = d->drv->chr_write(d->drv, buf, len); } else { int i; ret = 0; for (i = 0; i < len; i++) { if (d->linestar...
false
qemu
7bd427d801e1e3293a634d3c83beadaa90ffb911
static int mux_chr_write(CharDriverState *chr, const uint8_t *buf, int len) { MuxDriver *d = chr->opaque; int ret; if (!d->timestamps) { ret = d->drv->chr_write(d->drv, buf, len); } else { int i; ret = 0; for (i = 0; i < len; i++) { if (d->linestar...
{ "code": [], "line_no": [] }
static int FUNC_0(CharDriverState *VAR_0, const uint8_t *VAR_1, int VAR_2) { MuxDriver *d = VAR_0->opaque; int VAR_3; if (!d->timestamps) { VAR_3 = d->drv->chr_write(d->drv, VAR_1, VAR_2); } else { int VAR_4; VAR_3 = 0; for (VAR_4 = 0; VAR_4 < VAR_2; VAR_4++) {...
[ "static int FUNC_0(CharDriverState *VAR_0, const uint8_t *VAR_1, int VAR_2)\n{", "MuxDriver *d = VAR_0->opaque;", "int VAR_3;", "if (!d->timestamps) {", "VAR_3 = d->drv->chr_write(d->drv, VAR_1, VAR_2);", "} else {", "int VAR_4;", "VAR_3 = 0;", "for (VAR_4 = 0; VAR_4 < VAR_2; VAR_4++) {", "if (d->...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 33 ], [ 35, 37 ], [ 39 ], [ 41 ], [ 43, 45, 47, 49,...
6,088
int qio_channel_socket_listen_sync(QIOChannelSocket *ioc, SocketAddress *addr, Error **errp) { int fd; trace_qio_channel_socket_listen_sync(ioc, addr); fd = socket_listen(addr, errp); if (fd < 0) { trace_qio_channel_...
false
qemu
dfd100f242370886bb6732f70f1f7cbd8eb9fedc
int qio_channel_socket_listen_sync(QIOChannelSocket *ioc, SocketAddress *addr, Error **errp) { int fd; trace_qio_channel_socket_listen_sync(ioc, addr); fd = socket_listen(addr, errp); if (fd < 0) { trace_qio_channel_...
{ "code": [], "line_no": [] }
int FUNC_0(QIOChannelSocket *VAR_0, SocketAddress *VAR_1, Error **VAR_2) { int VAR_3; trace_qio_channel_socket_listen_sync(VAR_0, VAR_1); VAR_3 = socket_listen(VAR_1, VAR_2); if (VAR_3 < 0) { trace_qio_channel_socket...
[ "int FUNC_0(QIOChannelSocket *VAR_0,\nSocketAddress *VAR_1,\nError **VAR_2)\n{", "int VAR_3;", "trace_qio_channel_socket_listen_sync(VAR_0, VAR_1);", "VAR_3 = socket_listen(VAR_1, VAR_2);", "if (VAR_3 < 0) {", "trace_qio_channel_socket_listen_fail(VAR_0);", "return -1;", "}", "trace_qio_channel_sock...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5, 7 ], [ 9 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 41 ], [ 43 ] ]
6,089
static int rtc_post_load(void *opaque, int version_id) { RTCState *s = opaque; if (version_id <= 2 || rtc_clock == QEMU_CLOCK_REALTIME) { rtc_set_time(s); s->offset = 0; check_update_timer(s); } uint64_t now = qemu_clock_get_ns(rtc_clock); if (now < s->next_perio...
false
qemu
1dfb1b2d34840dce27e672f147bc4ef122abab74
static int rtc_post_load(void *opaque, int version_id) { RTCState *s = opaque; if (version_id <= 2 || rtc_clock == QEMU_CLOCK_REALTIME) { rtc_set_time(s); s->offset = 0; check_update_timer(s); } uint64_t now = qemu_clock_get_ns(rtc_clock); if (now < s->next_perio...
{ "code": [], "line_no": [] }
static int FUNC_0(void *VAR_0, int VAR_1) { RTCState *s = VAR_0; if (VAR_1 <= 2 || rtc_clock == QEMU_CLOCK_REALTIME) { rtc_set_time(s); s->offset = 0; check_update_timer(s); } uint64_t now = qemu_clock_get_ns(rtc_clock); if (now < s->next_periodic_time || ...
[ "static int FUNC_0(void *VAR_0, int VAR_1)\n{", "RTCState *s = VAR_0;", "if (VAR_1 <= 2 || rtc_clock == QEMU_CLOCK_REALTIME) {", "rtc_set_time(s);", "s->offset = 0;", "check_update_timer(s);", "}", "uint64_t now = qemu_clock_get_ns(rtc_clock);", "if (now < s->next_periodic_time ||\nnow > (s->next_pe...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 21 ], [ 23, 25 ], [ 27 ], [ 29 ], [ 33, 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45, 47 ], [ 49 ] ]
6,090
static void virtio_serial_save_device(VirtIODevice *vdev, QEMUFile *f) { VirtIOSerial *s = VIRTIO_SERIAL(vdev); VirtIOSerialPort *port; uint32_t nr_active_ports; unsigned int i, max_nr_ports; struct virtio_console_config config; /* The config space (ignored on the far end in current ver...
false
qemu
51b19ebe4320f3dcd93cea71235c1219318ddfd2
static void virtio_serial_save_device(VirtIODevice *vdev, QEMUFile *f) { VirtIOSerial *s = VIRTIO_SERIAL(vdev); VirtIOSerialPort *port; uint32_t nr_active_ports; unsigned int i, max_nr_ports; struct virtio_console_config config; get_config(vdev, (uint8_t *)&config); qemu_put_...
{ "code": [], "line_no": [] }
static void FUNC_0(VirtIODevice *VAR_0, QEMUFile *VAR_1) { VirtIOSerial *s = VIRTIO_SERIAL(VAR_0); VirtIOSerialPort *port; uint32_t nr_active_ports; unsigned int VAR_2, VAR_3; struct virtio_console_config VAR_4; get_config(VAR_0, (uint8_t *)&VAR_4); qemu_put_be16s(VAR_1, &VAR...
[ "static void FUNC_0(VirtIODevice *VAR_0, QEMUFile *VAR_1)\n{", "VirtIOSerial *s = VIRTIO_SERIAL(VAR_0);", "VirtIOSerialPort *port;", "uint32_t nr_active_ports;", "unsigned int VAR_2, VAR_3;", "struct virtio_console_config VAR_4;", "get_config(VAR_0, (uint8_t *)&VAR_4);", "qemu_put_be16s(VAR_1, &VAR_4....
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 45 ], [ 47 ], [ 49 ], [ 51 ], [ 55 ], [ 65 ...
6,091
static int init_directories(BDRVVVFATState* s, const char *dirname, int heads, int secs, Error **errp) { bootsector_t* bootsector; mapping_t* mapping; unsigned int i; unsigned int cluster; memset(&(s->first_sectors[0]),0,0x40*0x200); ...
false
qemu
d5941ddae82a35771656d7e35f64f7f8f19c5627
static int init_directories(BDRVVVFATState* s, const char *dirname, int heads, int secs, Error **errp) { bootsector_t* bootsector; mapping_t* mapping; unsigned int i; unsigned int cluster; memset(&(s->first_sectors[0]),0,0x40*0x200); ...
{ "code": [], "line_no": [] }
static int FUNC_0(BDRVVVFATState* VAR_0, const char *VAR_1, int VAR_2, int VAR_3, Error **VAR_4) { bootsector_t* bootsector; mapping_t* mapping; unsigned int VAR_5; unsigned int VAR_6; memset(&(VAR_0->first_sectors[0]),0,0x40*0x200); ...
[ "static int FUNC_0(BDRVVVFATState* VAR_0,\nconst char *VAR_1, int VAR_2, int VAR_3,\nError **VAR_4)\n{", "bootsector_t* bootsector;", "mapping_t* mapping;", "unsigned int VAR_5;", "unsigned int VAR_6;", "memset(&(VAR_0->first_sectors[0]),0,0x40*0x200);", "VAR_0->cluster_size=VAR_0->sectors_per_cluster*0...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ [ 1, 3, 5, 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 19 ], [ 23 ], [ 25 ], [ 43 ], [ 45 ], [ 49 ], [ 51 ], [ 57 ], [ 59 ], [ 61 ], [ 63 ], [ 65 ], [ 71 ], [ 75 ...
6,093
static void lsp2polyf(const double *lsp, double *f, int lp_half_order) { int i, j; f[0] = 1.0; f[1] = -2 * lsp[0]; lsp -= 2; for(i=2; i<=lp_half_order; i++) { double val = -2 * lsp[2*i]; f[i] = val * f[i-1] + 2*f[i-2]; for(j=i-1; j>1; j--) f[j] +=...
false
FFmpeg
33ae681f5ca9fa9aae82081dd6a6edbe2509f983
static void lsp2polyf(const double *lsp, double *f, int lp_half_order) { int i, j; f[0] = 1.0; f[1] = -2 * lsp[0]; lsp -= 2; for(i=2; i<=lp_half_order; i++) { double val = -2 * lsp[2*i]; f[i] = val * f[i-1] + 2*f[i-2]; for(j=i-1; j>1; j--) f[j] +=...
{ "code": [], "line_no": [] }
static void FUNC_0(const double *VAR_0, double *VAR_1, int VAR_2) { int VAR_3, VAR_4; VAR_1[0] = 1.0; VAR_1[1] = -2 * VAR_0[0]; VAR_0 -= 2; for(VAR_3=2; VAR_3<=VAR_2; VAR_3++) { double VAR_5 = -2 * VAR_0[2*VAR_3]; VAR_1[VAR_3] = VAR_5 * VAR_1[VAR_3-1] + 2*VAR_1[VAR_3-2...
[ "static void FUNC_0(const double *VAR_0, double *VAR_1, int VAR_2)\n{", "int VAR_3, VAR_4;", "VAR_1[0] = 1.0;", "VAR_1[1] = -2 * VAR_0[0];", "VAR_0 -= 2;", "for(VAR_3=2; VAR_3<=VAR_2; VAR_3++)", "{", "double VAR_5 = -2 * VAR_0[2*VAR_3];", "VAR_1[VAR_3] = VAR_5 * VAR_1[VAR_3-1] + 2*VAR_1[VAR_3-2];", ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ] ]
6,094
static uint32_t slow_bar_readl(void *opaque, target_phys_addr_t addr) { AssignedDevRegion *d = opaque; uint32_t *in = (uint32_t *)(d->u.r_virtbase + addr); uint32_t r; r = *in; DEBUG("slow_bar_readl addr=0x" TARGET_FMT_plx " val=0x%08x\n", addr, r); return r; }
false
qemu
a8170e5e97ad17ca169c64ba87ae2f53850dab4c
static uint32_t slow_bar_readl(void *opaque, target_phys_addr_t addr) { AssignedDevRegion *d = opaque; uint32_t *in = (uint32_t *)(d->u.r_virtbase + addr); uint32_t r; r = *in; DEBUG("slow_bar_readl addr=0x" TARGET_FMT_plx " val=0x%08x\n", addr, r); return r; }
{ "code": [], "line_no": [] }
static uint32_t FUNC_0(void *opaque, target_phys_addr_t addr) { AssignedDevRegion *d = opaque; uint32_t *in = (uint32_t *)(d->u.r_virtbase + addr); uint32_t r; r = *in; DEBUG("FUNC_0 addr=0x" TARGET_FMT_plx " val=0x%08x\n", addr, r); return r; }
[ "static uint32_t FUNC_0(void *opaque, target_phys_addr_t addr)\n{", "AssignedDevRegion *d = opaque;", "uint32_t *in = (uint32_t *)(d->u.r_virtbase + addr);", "uint32_t r;", "r = *in;", "DEBUG(\"FUNC_0 addr=0x\" TARGET_FMT_plx \" val=0x%08x\\n\", addr, r);", "return r;", "}" ]
[ 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 13 ], [ 15 ], [ 19 ], [ 21 ] ]
6,095
void ich9_pm_device_plug_cb(HotplugHandler *hotplug_dev, DeviceState *dev, Error **errp) { ICH9LPCState *lpc = ICH9_LPC_DEVICE(hotplug_dev); if (lpc->pm.acpi_memory_hotplug.is_enabled && object_dynamic_cast(OBJECT(dev), TYPE_PC_DIMM)) { acpi_memory_plug_cb(hot...
false
qemu
75f27498220e6ff6f78bf08fbe2cc662ec76ba89
void ich9_pm_device_plug_cb(HotplugHandler *hotplug_dev, DeviceState *dev, Error **errp) { ICH9LPCState *lpc = ICH9_LPC_DEVICE(hotplug_dev); if (lpc->pm.acpi_memory_hotplug.is_enabled && object_dynamic_cast(OBJECT(dev), TYPE_PC_DIMM)) { acpi_memory_plug_cb(hot...
{ "code": [], "line_no": [] }
void FUNC_0(HotplugHandler *VAR_0, DeviceState *VAR_1, Error **VAR_2) { ICH9LPCState *lpc = ICH9_LPC_DEVICE(VAR_0); if (lpc->pm.acpi_memory_hotplug.is_enabled && object_dynamic_cast(OBJECT(VAR_1), TYPE_PC_DIMM)) { acpi_memory_plug_cb(VAR_0, &lpc->pm.acpi_memor...
[ "void FUNC_0(HotplugHandler *VAR_0, DeviceState *VAR_1,\nError **VAR_2)\n{", "ICH9LPCState *lpc = ICH9_LPC_DEVICE(VAR_0);", "if (lpc->pm.acpi_memory_hotplug.is_enabled &&\nobject_dynamic_cast(OBJECT(VAR_1), TYPE_PC_DIMM)) {", "acpi_memory_plug_cb(VAR_0, &lpc->pm.acpi_memory_hotplug,\nVAR_1, VAR_2);", "} els...
[ 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 ] ]
6,096
static int megasas_dcmd_ld_get_list(MegasasState *s, MegasasCmd *cmd) { struct mfi_ld_list info; size_t dcmd_size = sizeof(info), resid; uint32_t num_ld_disks = 0, max_ld_disks = s->fw_luns; uint64_t ld_size; BusChild *kid; memset(&info, 0, dcmd_size); if (cmd->iov_size < dcmd_size...
false
qemu
4be746345f13e99e468c60acbd3a355e8183e3ce
static int megasas_dcmd_ld_get_list(MegasasState *s, MegasasCmd *cmd) { struct mfi_ld_list info; size_t dcmd_size = sizeof(info), resid; uint32_t num_ld_disks = 0, max_ld_disks = s->fw_luns; uint64_t ld_size; BusChild *kid; memset(&info, 0, dcmd_size); if (cmd->iov_size < dcmd_size...
{ "code": [], "line_no": [] }
static int FUNC_0(MegasasState *VAR_0, MegasasCmd *VAR_1) { struct mfi_ld_list VAR_2; size_t dcmd_size = sizeof(VAR_2), resid; uint32_t num_ld_disks = 0, max_ld_disks = VAR_0->fw_luns; uint64_t ld_size; BusChild *kid; memset(&VAR_2, 0, dcmd_size); if (VAR_1->iov_size < dcmd_size) {...
[ "static int FUNC_0(MegasasState *VAR_0, MegasasCmd *VAR_1)\n{", "struct mfi_ld_list VAR_2;", "size_t dcmd_size = sizeof(VAR_2), resid;", "uint32_t num_ld_disks = 0, max_ld_disks = VAR_0->fw_luns;", "uint64_t ld_size;", "BusChild *kid;", "memset(&VAR_2, 0, dcmd_size);", "if (VAR_1->iov_size < dcmd_size...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 17 ], [ 19 ], [ 21, 23 ], [ 25 ], [ 27 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 45 ], [ 47 ], [...
6,099
static void resume_all_vcpus(void) { CPUState *penv = first_cpu; while (penv) { penv->stop = 0; penv->stopped = 0; qemu_thread_signal(penv->thread, SIGUSR1); qemu_cpu_kick(penv); penv = (CPUState *)penv->next_cpu; } }
false
qemu
cc84de9570ffe01a9c3c169bd62ab9586a9a080c
static void resume_all_vcpus(void) { CPUState *penv = first_cpu; while (penv) { penv->stop = 0; penv->stopped = 0; qemu_thread_signal(penv->thread, SIGUSR1); qemu_cpu_kick(penv); penv = (CPUState *)penv->next_cpu; } }
{ "code": [], "line_no": [] }
static void FUNC_0(void) { CPUState *penv = first_cpu; while (penv) { penv->stop = 0; penv->stopped = 0; qemu_thread_signal(penv->thread, SIGUSR1); qemu_cpu_kick(penv); penv = (CPUState *)penv->next_cpu; } }
[ "static void FUNC_0(void)\n{", "CPUState *penv = first_cpu;", "while (penv) {", "penv->stop = 0;", "penv->stopped = 0;", "qemu_thread_signal(penv->thread, SIGUSR1);", "qemu_cpu_kick(penv);", "penv = (CPUState *)penv->next_cpu;", "}", "}" ]
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ] ]
6,100
static int coroutine_fn bdrv_co_writev_em(BlockDriverState *bs, int64_t sector_num, int nb_sectors, QEMUIOVector *iov) { return bdrv_co_io_em(bs, sector_num, nb_sectors, iov, true); }
false
qemu
08844473820c93541fc47bdfeae0f2cc88cfab59
static int coroutine_fn bdrv_co_writev_em(BlockDriverState *bs, int64_t sector_num, int nb_sectors, QEMUIOVector *iov) { return bdrv_co_io_em(bs, sector_num, nb_sectors, iov, true); }
{ "code": [], "line_no": [] }
static int VAR_0 bdrv_co_writev_em(BlockDriverState *bs, int64_t sector_num, int nb_sectors, QEMUIOVector *iov) { return bdrv_co_io_em(bs, sector_num, nb_sectors, iov, true); }
[ "static int VAR_0 bdrv_co_writev_em(BlockDriverState *bs,\nint64_t sector_num, int nb_sectors,\nQEMUIOVector *iov)\n{", "return bdrv_co_io_em(bs, sector_num, nb_sectors, iov, true);", "}" ]
[ 0, 0, 0 ]
[ [ 1, 3, 5, 7 ], [ 9 ], [ 11 ] ]
6,101
static void do_audio_out(AVFormatContext *s, AVOutputStream *ost, AVInputStream *ist, unsigned char *buf, int size) { uint8_t *buftmp; int64_t audio_out_size, audio_buf_size; int64_t allocated_for_size= size; int size_o...
false
FFmpeg
b926b6282d3b9fc8115660ae013f74f4f8c06d30
static void do_audio_out(AVFormatContext *s, AVOutputStream *ost, AVInputStream *ist, unsigned char *buf, int size) { uint8_t *buftmp; int64_t audio_out_size, audio_buf_size; int64_t allocated_for_size= size; int size_o...
{ "code": [], "line_no": [] }
static void FUNC_0(AVFormatContext *VAR_0, AVOutputStream *VAR_1, AVInputStream *VAR_2, unsigned char *VAR_3, int VAR_4) { uint8_t *buftmp; int64_t audio_out_size, audio_buf_size; int64_t allocated_for_size= VAR_4; int ...
[ "static void FUNC_0(AVFormatContext *VAR_0,\nAVOutputStream *VAR_1,\nAVInputStream *VAR_2,\nunsigned char *VAR_3, int VAR_4)\n{", "uint8_t *buftmp;", "int64_t audio_out_size, audio_buf_size;", "int64_t allocated_for_size= VAR_4;", "int VAR_5, VAR_6, VAR_7;", "AVCodecContext *enc= VAR_1->st->codec;", "AV...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ [ 1, 3, 5, 7, 9 ], [ 11 ], [ 13 ], [ 15 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 33, 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 47 ], [ 49, 51 ], [...
6,104
static int emulated_initfn(CCIDCardState *base) { EmulatedState *card = DO_UPCAST(EmulatedState, base, base); VCardEmulError ret; const EnumTable *ptable; QSIMPLEQ_INIT(&card->event_list); QSIMPLEQ_INIT(&card->guest_apdu_list); qemu_mutex_init(&card->event_list_mutex); qemu_mutex_i...
true
qemu
ae12e3a643c66575c77211e1226ada041e56b889
static int emulated_initfn(CCIDCardState *base) { EmulatedState *card = DO_UPCAST(EmulatedState, base, base); VCardEmulError ret; const EnumTable *ptable; QSIMPLEQ_INIT(&card->event_list); QSIMPLEQ_INIT(&card->guest_apdu_list); qemu_mutex_init(&card->event_list_mutex); qemu_mutex_i...
{ "code": [ " card->backend = parse_enumeration(card->backend_str, backend_enum_table, 0);", " printf(\"unknown backend, must be one of:\\n\");" ], "line_no": [ 35, 39 ] }
static int FUNC_0(CCIDCardState *VAR_0) { EmulatedState *card = DO_UPCAST(EmulatedState, VAR_0, VAR_0); VCardEmulError ret; const EnumTable *VAR_1; QSIMPLEQ_INIT(&card->event_list); QSIMPLEQ_INIT(&card->guest_apdu_list); qemu_mutex_init(&card->event_list_mutex); qemu_mutex_init(&ca...
[ "static int FUNC_0(CCIDCardState *VAR_0)\n{", "EmulatedState *card = DO_UPCAST(EmulatedState, VAR_0, VAR_0);", "VCardEmulError ret;", "const EnumTable *VAR_1;", "QSIMPLEQ_INIT(&card->event_list);", "QSIMPLEQ_INIT(&card->guest_apdu_list);", "qemu_mutex_init(&card->event_list_mutex);", "qemu_mutex_init(...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ...
6,105
static void mirror_exit(BlockJob *job, void *opaque) { MirrorBlockJob *s = container_of(job, MirrorBlockJob, common); MirrorExitData *data = opaque; AioContext *replace_aio_context = NULL; BlockDriverState *src = blk_bs(s->common.blk); BlockDriverState *target_bs = blk_bs(s->target); /*...
true
qemu
d4a92a8420ac764f21652322aa7d4e49cfcbc607
static void mirror_exit(BlockJob *job, void *opaque) { MirrorBlockJob *s = container_of(job, MirrorBlockJob, common); MirrorExitData *data = opaque; AioContext *replace_aio_context = NULL; BlockDriverState *src = blk_bs(s->common.blk); BlockDriverState *target_bs = blk_bs(s->target); ...
{ "code": [ " if (qemu_get_aio_context() == bdrv_get_aio_context(src)) {", " aio_enable_external(iohandler_get_aio_context());" ], "line_no": [ 103, 105 ] }
static void FUNC_0(BlockJob *VAR_0, void *VAR_1) { MirrorBlockJob *s = container_of(VAR_0, MirrorBlockJob, common); MirrorExitData *data = VAR_1; AioContext *replace_aio_context = NULL; BlockDriverState *src = blk_bs(s->common.blk); BlockDriverState *target_bs = blk_bs(s->target); ...
[ "static void FUNC_0(BlockJob *VAR_0, void *VAR_1)\n{", "MirrorBlockJob *s = container_of(VAR_0, MirrorBlockJob, common);", "MirrorExitData *data = VAR_1;", "AioContext *replace_aio_context = NULL;", "BlockDriverState *src = blk_bs(s->common.blk);", "BlockDriverState *target_bs = blk_bs(s->target);", "bd...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 21 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 47 ], [ 49 ], [ 51 ], [ 59 ...
6,106
static void init_proc_620 (CPUPPCState *env) { gen_spr_ne_601(env); gen_spr_620(env); /* Time base */ gen_tbl(env); /* Hardware implementation registers */ /* XXX : not implemented */ spr_register(env, SPR_HID0, "HID0", SPR_NOACCESS, SPR_NOACCESS, ...
true
qemu
faadf50e2962dd54175647a80bd6fc4319c91973
static void init_proc_620 (CPUPPCState *env) { gen_spr_ne_601(env); gen_spr_620(env); gen_tbl(env); spr_register(env, SPR_HID0, "HID0", SPR_NOACCESS, SPR_NOACCESS, &spr_read_generic, &spr_write_generic, 0x00000000); ...
{ "code": [ " 0x00000000);" ], "line_no": [ 23 ] }
static void FUNC_0 (CPUPPCState *VAR_0) { gen_spr_ne_601(VAR_0); gen_spr_620(VAR_0); gen_tbl(VAR_0); spr_register(VAR_0, SPR_HID0, "HID0", SPR_NOACCESS, SPR_NOACCESS, &spr_read_generic, &spr_write_generic, 0x00000000); ...
[ "static void FUNC_0 (CPUPPCState *VAR_0)\n{", "gen_spr_ne_601(VAR_0);", "gen_spr_620(VAR_0);", "gen_tbl(VAR_0);", "spr_register(VAR_0, SPR_HID0, \"HID0\",\nSPR_NOACCESS, SPR_NOACCESS,\n&spr_read_generic, &spr_write_generic,\n0x00000000);", "gen_low_BATs(VAR_0);", "gen_high_BATs(VAR_0);", "init_excp_62...
[ 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 11 ], [ 17, 19, 21, 23 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 39 ] ]
6,109
static inline void gen_intermediate_code_internal(PowerPCCPU *cpu, TranslationBlock *tb, bool search_pc) { CPUState *cs = CPU(cpu); CPUPPCState *env = &cpu->env; DisasContext ctx, *ctxp = &ctx; opc...
true
qemu
3de31797825e94fd67ee7c2e877127acc3d2edbd
static inline void gen_intermediate_code_internal(PowerPCCPU *cpu, TranslationBlock *tb, bool search_pc) { CPUState *cs = CPU(cpu); CPUPPCState *env = &cpu->env; DisasContext ctx, *ctxp = &ctx; opc...
{ "code": [], "line_no": [] }
static inline void FUNC_0(PowerPCCPU *VAR_0, TranslationBlock *VAR_1, bool VAR_2) { CPUState *cs = CPU(VAR_0); CPUPPCState *env = &VAR_0->env; DisasContext ctx, *ctxp = &ctx; opc_handler_t **table,...
[ "static inline void FUNC_0(PowerPCCPU *VAR_0,\nTranslationBlock *VAR_1,\nbool VAR_2)\n{", "CPUState *cs = CPU(VAR_0);", "CPUPPCState *env = &VAR_0->env;", "DisasContext ctx, *ctxp = &ctx;", "opc_handler_t **table, *handler;", "target_ulong pc_start;", "uint16_t *gen_opc_end;", "CPUBreakpoint *bp;", ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ [ 1, 3, 5, 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ...
6,110
static void gen_mfsri(DisasContext *ctx) { #if defined(CONFIG_USER_ONLY) gen_inval_exception(ctx, POWERPC_EXCP_PRIV_OPC); #else int ra = rA(ctx->opcode); int rd = rD(ctx->opcode); TCGv t0; if (unlikely(ctx->pr)) { gen_inval_exception(ctx, POWERPC_EXCP_PRIV_OPC); return; ...
true
qemu
9b2fadda3e0196ffd485adde4fe9cdd6fae35300
static void gen_mfsri(DisasContext *ctx) { #if defined(CONFIG_USER_ONLY) gen_inval_exception(ctx, POWERPC_EXCP_PRIV_OPC); #else int ra = rA(ctx->opcode); int rd = rD(ctx->opcode); TCGv t0; if (unlikely(ctx->pr)) { gen_inval_exception(ctx, POWERPC_EXCP_PRIV_OPC); return; ...
{ "code": [ " gen_inval_exception(ctx, POWERPC_EXCP_PRIV_OPC);", " gen_inval_exception(ctx, POWERPC_EXCP_PRIV_OPC);", " if (unlikely(ctx->pr)) {", " gen_inval_exception(ctx, POWERPC_EXCP_PRIV_OPC);", " gen_inval_exception(ctx, POWERPC_EXCP_PRIV_OPC);", " if (unlikely(...
static void FUNC_0(DisasContext *VAR_0) { #if defined(CONFIG_USER_ONLY) gen_inval_exception(VAR_0, POWERPC_EXCP_PRIV_OPC); #else int VAR_1 = rA(VAR_0->opcode); int VAR_2 = rD(VAR_0->opcode); TCGv t0; if (unlikely(VAR_0->pr)) { gen_inval_exception(VAR_0, POWERPC_EXCP_PRIV_OPC); ...
[ "static void FUNC_0(DisasContext *VAR_0)\n{", "#if defined(CONFIG_USER_ONLY)\ngen_inval_exception(VAR_0, POWERPC_EXCP_PRIV_OPC);", "#else\nint VAR_1 = rA(VAR_0->opcode);", "int VAR_2 = rD(VAR_0->opcode);", "TCGv t0;", "if (unlikely(VAR_0->pr)) {", "gen_inval_exception(VAR_0, POWERPC_EXCP_PRIV_OPC);", ...
[ 0, 1, 1, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1 ]
[ [ 1, 3 ], [ 5, 7 ], [ 9, 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37, 39 ], [ 41, 43 ] ]
6,111
static int rv20_decode_picture_header(MpegEncContext *s) { int seq, mb_pos, i; if(s->avctx->sub_id == 0x30202002 || s->avctx->sub_id == 0x30203002){ if (get_bits(&s->gb, 3)){ av_log(s->avctx, AV_LOG_ERROR, "unknown triplet set\n"); return -1; } } ...
true
FFmpeg
bed1707c9c274831173902542aaef1f8428e6331
static int rv20_decode_picture_header(MpegEncContext *s) { int seq, mb_pos, i; if(s->avctx->sub_id == 0x30202002 || s->avctx->sub_id == 0x30203002){ if (get_bits(&s->gb, 3)){ av_log(s->avctx, AV_LOG_ERROR, "unknown triplet set\n"); return -1; } } ...
{ "code": [ " return -1;" ], "line_no": [ 15 ] }
static int FUNC_0(MpegEncContext *VAR_0) { int VAR_1, VAR_2, VAR_3; if(VAR_0->avctx->sub_id == 0x30202002 || VAR_0->avctx->sub_id == 0x30203002){ if (get_bits(&VAR_0->gb, 3)){ av_log(VAR_0->avctx, AV_LOG_ERROR, "unknown triplet set\n"); return -1; } } ...
[ "static int FUNC_0(MpegEncContext *VAR_0)\n{", "int VAR_1, VAR_2, VAR_3;", "if(VAR_0->avctx->sub_id == 0x30202002 || VAR_0->avctx->sub_id == 0x30203002){", "if (get_bits(&VAR_0->gb, 3)){", "av_log(VAR_0->avctx, AV_LOG_ERROR, \"unknown triplet set\\n\");", "return -1;", "}", "}", "VAR_3= get_bits(&VA...
[ 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, 0, 0...
[ [ 1, 3 ], [ 5 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35, 37 ], [ 39 ], [ 41 ], [ 45 ], [ 47 ], ...
6,113
static void hpet_timer(void *opaque) { HPETTimer *t = (HPETTimer*)opaque; uint64_t diff; uint64_t period = t->period; uint64_t cur_tick = hpet_get_ticks(); if (timer_is_periodic(t) && period != 0) { if (t->config & HPET_TN_32BIT) { while (hpet_time_after(cur_tick, t->...
true
qemu
27bb0b2d6f80f058bdb6fcc8fcdfa69b0c8a6d71
static void hpet_timer(void *opaque) { HPETTimer *t = (HPETTimer*)opaque; uint64_t diff; uint64_t period = t->period; uint64_t cur_tick = hpet_get_ticks(); if (timer_is_periodic(t) && period != 0) { if (t->config & HPET_TN_32BIT) { while (hpet_time_after(cur_tick, t->...
{ "code": [ " } else", " HPETTimer *t = (HPETTimer*)opaque;", " while (hpet_time_after(cur_tick, t->cmp))", " } else", " while (hpet_time_after64(cur_tick, t->cmp))", " qemu_mod_timer(t->qemu_timer, qemu_get_clock(vm_clock)", " ...
static void FUNC_0(void *VAR_0) { HPETTimer *t = (HPETTimer*)VAR_0; uint64_t diff; uint64_t period = t->period; uint64_t cur_tick = hpet_get_ticks(); if (timer_is_periodic(t) && period != 0) { if (t->config & HPET_TN_32BIT) { while (hpet_time_after(cur_tick, t->cmp)) ...
[ "static void FUNC_0(void *VAR_0)\n{", "HPETTimer *t = (HPETTimer*)VAR_0;", "uint64_t diff;", "uint64_t period = t->period;", "uint64_t cur_tick = hpet_get_ticks();", "if (timer_is_periodic(t) && period != 0) {", "if (t->config & HPET_TN_32BIT) {", "while (hpet_time_after(cur_tick, t->cmp))\nt->cmp = (...
[ 0, 1, 0, 0, 0, 0, 0, 1, 0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 11 ], [ 13 ], [ 17 ], [ 19 ], [ 21, 23 ], [ 25 ], [ 27, 29 ], [ 33 ], [ 35, 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45, 47 ], [ 49 ], [ 51...
6,114
static AddrRange addrrange_make(uint64_t start, uint64_t size) { return (AddrRange) { start, size }; }
true
qemu
8417cebfda193c7f9ca70be5e308eaa92cf84b94
static AddrRange addrrange_make(uint64_t start, uint64_t size) { return (AddrRange) { start, size }; }
{ "code": [ "static AddrRange addrrange_make(uint64_t start, uint64_t size)" ], "line_no": [ 1 ] }
static AddrRange FUNC_0(uint64_t start, uint64_t size) { return (AddrRange) { start, size }; }
[ "static AddrRange FUNC_0(uint64_t start, uint64_t size)\n{", "return (AddrRange) { start, size };", "}" ]
[ 1, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ] ]
6,115
int bdrv_file_open(BlockDriverState **pbs, const char *filename, const char *reference, QDict *options, int flags, Error **errp) { BlockDriverState *bs = NULL; BlockDriver *drv; const char *drvname; bool allow_protocol_prefix = false; Error *local_err = ...
true
qemu
765003db029ed4660a09807958276e251de84fac
int bdrv_file_open(BlockDriverState **pbs, const char *filename, const char *reference, QDict *options, int flags, Error **errp) { BlockDriverState *bs = NULL; BlockDriver *drv; const char *drvname; bool allow_protocol_prefix = false; Error *local_err = ...
{ "code": [ " } else if (drv->bdrv_needs_filename && !filename) {", " error_setg(errp, \"The '%s' block driver requires a file name\",", " drv->format_name);", " ret = -EINVAL;", " goto fail;" ], "line_no": [ 169, 171, 173, 95, 97 ...
int FUNC_0(BlockDriverState **VAR_0, const char *VAR_1, const char *VAR_2, QDict *VAR_3, int VAR_4, Error **VAR_5) { BlockDriverState *bs = NULL; BlockDriver *drv; const char *VAR_6; bool allow_protocol_prefix = false; Error *local_err = NULL; int V...
[ "int FUNC_0(BlockDriverState **VAR_0, const char *VAR_1,\nconst char *VAR_2, QDict *VAR_3, int VAR_4,\nError **VAR_5)\n{", "BlockDriverState *bs = NULL;", "BlockDriver *drv;", "const char *VAR_6;", "bool allow_protocol_prefix = false;", "Error *local_err = NULL;", "int VAR_7;", "if (VAR_3 == NULL) {",...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ [ 1, 3, 5, 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 25 ], [ 27 ], [ 29 ], [ 33 ], [ 35 ], [ 37, 39 ], [ 41 ], [ 43 ], [ 45 ], [ 49 ], [ 51 ], [...
6,116
static av_cold int concat_open(URLContext *h, const char *uri, int flags) { char *node_uri = NULL; int err = 0; int64_t size; size_t len, i; URLContext *uc; struct concat_data *data = h->priv_data; struct concat_nodes *nodes; av_strstart(uri, "concat:", &uri); for (i ...
true
FFmpeg
ad2a08388c82bdec5ac9355ca6e0bc4c98b26423
static av_cold int concat_open(URLContext *h, const char *uri, int flags) { char *node_uri = NULL; int err = 0; int64_t size; size_t len, i; URLContext *uc; struct concat_data *data = h->priv_data; struct concat_nodes *nodes; av_strstart(uri, "concat:", &uri); for (i ...
{ "code": [ " else if ((err = av_reallocp(&nodes, data->length * sizeof(*nodes))) < 0)" ], "line_no": [ 115 ] }
static av_cold int FUNC_0(URLContext *h, const char *uri, int flags) { char *VAR_0 = NULL; int VAR_1 = 0; int64_t size; size_t len, i; URLContext *uc; struct concat_data *VAR_2 = h->priv_data; struct concat_nodes *VAR_3; av_strstart(uri, "concat:", &uri); for (i = 0, ...
[ "static av_cold int FUNC_0(URLContext *h, const char *uri, int flags)\n{", "char *VAR_0 = NULL;", "int VAR_1 = 0;", "int64_t size;", "size_t len, i;", "URLContext *uc;", "struct concat_data *VAR_2 = h->priv_data;", "struct concat_nodes *VAR_3;", "av_strstart(uri, \"concat:\", &uri);", "for (i = ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 21 ], [ 25 ], [ 27, 31 ], [ 33 ], [ 35 ], [ 37 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ], [ 53, 55 ...
6,117
static int encode_frame(AVCodecContext *avctx, AVPacket *avpkt, const AVFrame *frame, int *got_packet_ptr) { DCAEncContext *c = avctx->priv_data; const int32_t *samples; int ret, i; if ((ret = ff_alloc_packet2(avctx, avpkt, c->frame_size , 0)) < 0) return ret; samples...
true
FFmpeg
e322b7061f873e8fd33b9e518caa19b87616a528
static int encode_frame(AVCodecContext *avctx, AVPacket *avpkt, const AVFrame *frame, int *got_packet_ptr) { DCAEncContext *c = avctx->priv_data; const int32_t *samples; int ret, i; if ((ret = ff_alloc_packet2(avctx, avpkt, c->frame_size , 0)) < 0) return ret; samples...
{ "code": [], "line_no": [] }
static int FUNC_0(AVCodecContext *VAR_0, AVPacket *VAR_1, const AVFrame *VAR_2, int *VAR_3) { DCAEncContext *c = VAR_0->priv_data; const int32_t *VAR_4; int VAR_5, VAR_6; if ((VAR_5 = ff_alloc_packet2(VAR_0, VAR_1, c->frame_size , 0)) < 0) return VAR_5; VAR_4 = (const...
[ "static int FUNC_0(AVCodecContext *VAR_0, AVPacket *VAR_1,\nconst AVFrame *VAR_2, int *VAR_3)\n{", "DCAEncContext *c = VAR_0->priv_data;", "const int32_t *VAR_4;", "int VAR_5, VAR_6;", "if ((VAR_5 = ff_alloc_packet2(VAR_0, VAR_1, c->frame_size , 0)) < 0)\nreturn VAR_5;", "VAR_4 = (const int32_t *)VAR_2->d...
[ 0, 0, 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 ], [ ...
6,118
static void qobject_input_type_null(Visitor *v, const char *name, Error **errp) { QObjectInputVisitor *qiv = to_qiv(v); QObject *qobj = qobject_input_get_object(qiv, name, true, errp); if (!qobj) { return; } if (qobject_type(qobj) != QTYPE_QNULL) { error_setg(errp, QERR_I...
true
qemu
a9fc37f6bc3f2ab90585cb16493da9f6dcfbfbcf
static void qobject_input_type_null(Visitor *v, const char *name, Error **errp) { QObjectInputVisitor *qiv = to_qiv(v); QObject *qobj = qobject_input_get_object(qiv, name, true, errp); if (!qobj) { return; } if (qobject_type(qobj) != QTYPE_QNULL) { error_setg(errp, QERR_I...
{ "code": [ " error_setg(errp, QERR_INVALID_PARAMETER_TYPE, name ? name : \"null\",", " error_setg(errp, QERR_INVALID_PARAMETER_TYPE, name ? name : \"null\",", " error_setg(errp, QERR_INVALID_PARAMETER_TYPE, name ? name : \"null\",", " error_setg(errp, QERR_INVALID_PARAMETE...
static void FUNC_0(Visitor *VAR_0, const char *VAR_1, Error **VAR_2) { QObjectInputVisitor *qiv = to_qiv(VAR_0); QObject *qobj = qobject_input_get_object(qiv, VAR_1, true, VAR_2); if (!qobj) { return; } if (qobject_type(qobj) != QTYPE_QNULL) { error_setg(VAR_2, QERR_INVAL...
[ "static void FUNC_0(Visitor *VAR_0, const char *VAR_1, Error **VAR_2)\n{", "QObjectInputVisitor *qiv = to_qiv(VAR_0);", "QObject *qobj = qobject_input_get_object(qiv, VAR_1, true, VAR_2);", "if (!qobj) {", "return;", "}", "if (qobject_type(qobj) != QTYPE_QNULL) {", "error_setg(VAR_2, QERR_INVALID_PARA...
[ 0, 0, 0, 0, 0, 0, 0, 1, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 11 ], [ 13 ], [ 15 ], [ 19 ], [ 21, 23 ], [ 25 ], [ 27 ] ]
6,119
void ff_subblock_synthesis(RA144Context *ractx, const int16_t *lpc_coefs, int cba_idx, int cb1_idx, int cb2_idx, int gval, int gain) { int16_t *block; int m[3]; if (cba_idx) { cba_idx += BLOCKSIZE/2 - 1; ff_copy_and_dup(ractx->b...
true
FFmpeg
4c472c52525fcab4c80cdbc98b4625d318c84fcb
void ff_subblock_synthesis(RA144Context *ractx, const int16_t *lpc_coefs, int cba_idx, int cb1_idx, int cb2_idx, int gval, int gain) { int16_t *block; int m[3]; if (cba_idx) { cba_idx += BLOCKSIZE/2 - 1; ff_copy_and_dup(ractx->b...
{ "code": [ " m[0] = (ff_irms(&ractx->adsp, ractx->buffer_a) * gval) >> 12;" ], "line_no": [ 21 ] }
void FUNC_0(RA144Context *VAR_0, const int16_t *VAR_1, int VAR_2, int VAR_3, int VAR_4, int VAR_5, int VAR_6) { int16_t *block; int VAR_7[3]; if (VAR_2) { VAR_2 += BLOCKSIZE/2 - 1; ff_copy_and_dup(VAR_0->buffer_a, VAR_0->adapt_c...
[ "void FUNC_0(RA144Context *VAR_0, const int16_t *VAR_1,\nint VAR_2, int VAR_3, int VAR_4,\nint VAR_5, int VAR_6)\n{", "int16_t *block;", "int VAR_7[3];", "if (VAR_2) {", "VAR_2 += BLOCKSIZE/2 - 1;", "ff_copy_and_dup(VAR_0->buffer_a, VAR_0->adapt_cb, VAR_2);", "VAR_7[0] = (ff_irms(&VAR_0->adsp, VAR_0->bu...
[ 0, 0, 0, 0, 0, 0, 1, 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 ], [ 39 ], [ 43, 45 ], [ 49, 51 ], [ 55, 57,...
6,120
static struct omap_prcm_s *omap_prcm_init(struct omap_target_agent_s *ta, qemu_irq mpu_int, qemu_irq dsp_int, qemu_irq iva_int, struct omap_mpu_state_s *mpu) { struct omap_prcm_s *s = (struct omap_prcm_s *) g_malloc0(sizeof(struct omap_prcm_s)); s->irq[0] = mp...
true
qemu
b45c03f585ea9bb1af76c73e82195418c294919d
static struct omap_prcm_s *omap_prcm_init(struct omap_target_agent_s *ta, qemu_irq mpu_int, qemu_irq dsp_int, qemu_irq iva_int, struct omap_mpu_state_s *mpu) { struct omap_prcm_s *s = (struct omap_prcm_s *) g_malloc0(sizeof(struct omap_prcm_s)); s->irq[0] = mp...
{ "code": [ " struct omap_prcm_s *s = (struct omap_prcm_s *)", " g_malloc0(sizeof(struct omap_prcm_s));" ], "line_no": [ 9, 11 ] }
static struct omap_prcm_s *FUNC_0(struct omap_target_agent_s *VAR_0, qemu_irq VAR_1, qemu_irq VAR_2, qemu_irq VAR_3, struct omap_mpu_state_s *VAR_4) { struct omap_prcm_s *VAR_5 = (struct omap_prcm_s *) g_malloc0(sizeof(struct omap_prcm_s)); VAR_5->irq[0] = VAR...
[ "static struct omap_prcm_s *FUNC_0(struct omap_target_agent_s *VAR_0,\nqemu_irq VAR_1, qemu_irq VAR_2, qemu_irq VAR_3,\nstruct omap_mpu_state_s *VAR_4)\n{", "struct omap_prcm_s *VAR_5 = (struct omap_prcm_s *)\ng_malloc0(sizeof(struct omap_prcm_s));", "VAR_5->irq[0] = VAR_1;", "VAR_5->irq[1] = VAR_2;", "VAR_...
[ 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5, 7 ], [ 9, 11 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 27, 29 ], [ 31, 33 ], [ 35 ], [ 37 ], [ 41 ], [ 43 ] ]
6,121
static void close_file(OutputStream *os) { int64_t pos = avio_tell(os->out); avio_seek(os->out, 0, SEEK_SET); avio_wb32(os->out, pos); avio_flush(os->out); avio_close(os->out); os->out = NULL; }
false
FFmpeg
9f61abc8111c7c43f49ca012e957a108b9cc7610
static void close_file(OutputStream *os) { int64_t pos = avio_tell(os->out); avio_seek(os->out, 0, SEEK_SET); avio_wb32(os->out, pos); avio_flush(os->out); avio_close(os->out); os->out = NULL; }
{ "code": [], "line_no": [] }
static void FUNC_0(OutputStream *VAR_0) { int64_t pos = avio_tell(VAR_0->out); avio_seek(VAR_0->out, 0, SEEK_SET); avio_wb32(VAR_0->out, pos); avio_flush(VAR_0->out); avio_close(VAR_0->out); VAR_0->out = NULL; }
[ "static void FUNC_0(OutputStream *VAR_0)\n{", "int64_t pos = avio_tell(VAR_0->out);", "avio_seek(VAR_0->out, 0, SEEK_SET);", "avio_wb32(VAR_0->out, pos);", "avio_flush(VAR_0->out);", "avio_close(VAR_0->out);", "VAR_0->out = NULL;", "}" ]
[ 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ] ]
6,122
static int g726_encode_frame(AVCodecContext *avctx, AVPacket *avpkt, const AVFrame *frame, int *got_packet_ptr) { G726Context *c = avctx->priv_data; const int16_t *samples = (const int16_t *)frame->data[0]; PutBitContext pb; int i, ret, out_size; out_size = (fra...
false
FFmpeg
bcaf64b605442e1622d16da89d4ec0e7730b8a8c
static int g726_encode_frame(AVCodecContext *avctx, AVPacket *avpkt, const AVFrame *frame, int *got_packet_ptr) { G726Context *c = avctx->priv_data; const int16_t *samples = (const int16_t *)frame->data[0]; PutBitContext pb; int i, ret, out_size; out_size = (fra...
{ "code": [], "line_no": [] }
static int FUNC_0(AVCodecContext *VAR_0, AVPacket *VAR_1, const AVFrame *VAR_2, int *VAR_3) { G726Context *c = VAR_0->priv_data; const int16_t *VAR_4 = (const int16_t *)VAR_2->data[0]; PutBitContext pb; int VAR_5, VAR_6, VAR_7; VAR_7 = (VAR_2->nb_samples * c->co...
[ "static int FUNC_0(AVCodecContext *VAR_0, AVPacket *VAR_1,\nconst AVFrame *VAR_2, int *VAR_3)\n{", "G726Context *c = VAR_0->priv_data;", "const int16_t *VAR_4 = (const int16_t *)VAR_2->data[0];", "PutBitContext pb;", "int VAR_5, VAR_6, VAR_7;", "VAR_7 = (VAR_2->nb_samples * c->code_size + 7) / 8;", "if ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 17 ], [ 19, 21 ], [ 23 ], [ 27 ], [ 29 ], [ 33 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ] ]
6,123
static int virtio_rng_load(QEMUFile *f, void *opaque, int version_id) { if (version_id != 1) { return -EINVAL; } return virtio_load(VIRTIO_DEVICE(opaque), f, version_id); }
true
qemu
db12451decf7dfe0f083564183e135f2095228b9
static int virtio_rng_load(QEMUFile *f, void *opaque, int version_id) { if (version_id != 1) { return -EINVAL; } return virtio_load(VIRTIO_DEVICE(opaque), f, version_id); }
{ "code": [ " return virtio_load(VIRTIO_DEVICE(opaque), f, version_id);" ], "line_no": [ 11 ] }
static int FUNC_0(QEMUFile *VAR_0, void *VAR_1, int VAR_2) { if (VAR_2 != 1) { return -EINVAL; } return virtio_load(VIRTIO_DEVICE(VAR_1), VAR_0, VAR_2); }
[ "static int FUNC_0(QEMUFile *VAR_0, void *VAR_1, int VAR_2)\n{", "if (VAR_2 != 1) {", "return -EINVAL;", "}", "return virtio_load(VIRTIO_DEVICE(VAR_1), VAR_0, VAR_2);", "}" ]
[ 0, 0, 0, 0, 1, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ] ]
6,124
static void dpy_refresh(DisplayState *s) { DisplayChangeListener *dcl; QLIST_FOREACH(dcl, &s->listeners, next) { if (dcl->ops->dpy_refresh) { dcl->ops->dpy_refresh(dcl); } } }
true
qemu
8bb93c6f99a42c2e0943bc904b283cd622d302c5
static void dpy_refresh(DisplayState *s) { DisplayChangeListener *dcl; QLIST_FOREACH(dcl, &s->listeners, next) { if (dcl->ops->dpy_refresh) { dcl->ops->dpy_refresh(dcl); } } }
{ "code": [ " dcl->ops->dpy_refresh(dcl);" ], "line_no": [ 13 ] }
static void FUNC_0(DisplayState *VAR_0) { DisplayChangeListener *dcl; QLIST_FOREACH(dcl, &VAR_0->listeners, next) { if (dcl->ops->FUNC_0) { dcl->ops->FUNC_0(dcl); } } }
[ "static void FUNC_0(DisplayState *VAR_0)\n{", "DisplayChangeListener *dcl;", "QLIST_FOREACH(dcl, &VAR_0->listeners, next) {", "if (dcl->ops->FUNC_0) {", "dcl->ops->FUNC_0(dcl);", "}", "}", "}" ]
[ 0, 0, 0, 0, 1, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ] ]
6,126
static void sysbus_ahci_class_init(ObjectClass *klass, void *data) { DeviceClass *dc = DEVICE_CLASS(klass); dc->realize = sysbus_ahci_realize; dc->vmsd = &vmstate_sysbus_ahci; dc->props = sysbus_ahci_properties; dc->reset = sysbus_ahci_reset; set_bit(DEVICE_CATEGORY_STORAGE, dc->categor...
true
qemu
e4f4fb1eca795e36f363b4647724221e774523c1
static void sysbus_ahci_class_init(ObjectClass *klass, void *data) { DeviceClass *dc = DEVICE_CLASS(klass); dc->realize = sysbus_ahci_realize; dc->vmsd = &vmstate_sysbus_ahci; dc->props = sysbus_ahci_properties; dc->reset = sysbus_ahci_reset; set_bit(DEVICE_CATEGORY_STORAGE, dc->categor...
{ "code": [], "line_no": [] }
static void FUNC_0(ObjectClass *VAR_0, void *VAR_1) { DeviceClass *dc = DEVICE_CLASS(VAR_0); dc->realize = sysbus_ahci_realize; dc->vmsd = &vmstate_sysbus_ahci; dc->props = sysbus_ahci_properties; dc->reset = sysbus_ahci_reset; set_bit(DEVICE_CATEGORY_STORAGE, dc->categories); }
[ "static void FUNC_0(ObjectClass *VAR_0, void *VAR_1)\n{", "DeviceClass *dc = DEVICE_CLASS(VAR_0);", "dc->realize = sysbus_ahci_realize;", "dc->vmsd = &vmstate_sysbus_ahci;", "dc->props = sysbus_ahci_properties;", "dc->reset = sysbus_ahci_reset;", "set_bit(DEVICE_CATEGORY_STORAGE, dc->categories);", "}...
[ 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 24 ] ]
6,127
static void read_apic(AVFormatContext *s, AVIOContext *pb, int taglen, char *tag, ID3v2ExtraMeta **extra_meta) { int enc, pic_type; char mimetype[64]; const CodecMime *mime = ff_id3v2_mime_tags; enum AVCodecID id = AV_CODEC_ID_NONE; ID3v2ExtraMetaAPIC *apic = NULL; ...
true
FFmpeg
24cfe91a220204e56394c85bca51799b77df175b
static void read_apic(AVFormatContext *s, AVIOContext *pb, int taglen, char *tag, ID3v2ExtraMeta **extra_meta) { int enc, pic_type; char mimetype[64]; const CodecMime *mime = ff_id3v2_mime_tags; enum AVCodecID id = AV_CODEC_ID_NONE; ID3v2ExtraMetaAPIC *apic = NULL; ...
{ "code": [ " apic->buf = av_buffer_alloc(taglen);" ], "line_no": [ 103 ] }
static void FUNC_0(AVFormatContext *VAR_0, AVIOContext *VAR_1, int VAR_2, char *VAR_3, ID3v2ExtraMeta **VAR_4) { int VAR_5, VAR_6; char VAR_7[64]; const CodecMime *VAR_8 = ff_id3v2_mime_tags; enum AVCodecID VAR_9 = AV_CODEC_ID_NONE; ID3v2ExtraMetaAPIC *apic = NULL; ...
[ "static void FUNC_0(AVFormatContext *VAR_0, AVIOContext *VAR_1, int VAR_2, char *VAR_3, ID3v2ExtraMeta **VAR_4)\n{", "int VAR_5, VAR_6;", "char VAR_7[64];", "const CodecMime *VAR_8 = ff_id3v2_mime_tags;", "enum AVCodecID VAR_9 = AV_CODEC_ID_NONE;", "ID3v2ExtraMetaAPIC *apic = NU...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 21, 23 ], [ 27 ], [ 29 ], [ 31, 33 ], [ 37 ], [ 39 ], [ 45 ], [ 47 ], [ 49 ], [ 51 ], [ 53 ...
6,128
readv_f(int argc, char **argv) { struct timeval t1, t2; int Cflag = 0, qflag = 0, vflag = 0; int c, cnt; char *buf; int64_t offset; int total; int nr_iov; QEMUIOVector qiov; int pattern = 0; int Pflag = 0; while ((c = getopt(argc, argv, "CP:qv")) != EOF) { switch (c) { case 'C': Cflag...
true
qemu
7d8abfcb50a33aed369bbd267852cf04009c49e9
readv_f(int argc, char **argv) { struct timeval t1, t2; int Cflag = 0, qflag = 0, vflag = 0; int c, cnt; char *buf; int64_t offset; int total; int nr_iov; QEMUIOVector qiov; int pattern = 0; int Pflag = 0; while ((c = getopt(argc, argv, "CP:qv")) != EOF) { switch (c) { case 'C': Cflag...
{ "code": [ "\t\treturn 0;", "\t\treturn 0;", "\t\treturn 0;", "\t\treturn 0;", "\t\treturn 0;", "\t\treturn 0;", "\t\treturn 0;", "\t\treturn 0;", "\tif (optind > argc - 2)", "\tif (optind > argc - 2)" ], "line_no": [ 81, 81, 81, 81, 81, 81, 81,...
FUNC_0(int VAR_0, char **VAR_1) { struct timeval VAR_2, VAR_3; int VAR_4 = 0, VAR_5 = 0, VAR_6 = 0; int VAR_7, VAR_8; char *VAR_9; int64_t offset; int VAR_10; int VAR_11; QEMUIOVector qiov; int VAR_12 = 0; int VAR_13 = 0; while ((VAR_7 = getopt(VAR_0, VAR_1, "CP:qv")) != EOF) { switch (VAR_7...
[ "FUNC_0(int VAR_0, char **VAR_1)\n{", "struct timeval VAR_2, VAR_3;", "int VAR_4 = 0, VAR_5 = 0, VAR_6 = 0;", "int VAR_7, VAR_8;", "char *VAR_9;", "int64_t offset;", "int VAR_10;", "int VAR_11;", "QEMUIOVector qiov;", "int VAR_12 = 0;", "int VAR_13 = 0;", "while ((VAR_7 = getopt(VAR_0, 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, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 27 ], [ 29 ], [ 31, 33 ], [ 35 ], [ 37, 39 ], [ 41 ], [ 43 ], [ 45,...
6,130
static int opt_vstats(void *optctx, const char *opt, const char *arg) { char filename[40]; time_t today2 = time(NULL); struct tm *today = localtime(&today2); snprintf(filename, sizeof(filename), "vstats_%02d%02d%02d.log", today->tm_hour, today->tm_min, today->tm_sec); return opt_vstats_...
true
FFmpeg
8e91d9652ea5048d9014e7636e12c6ed4732d7b7
static int opt_vstats(void *optctx, const char *opt, const char *arg) { char filename[40]; time_t today2 = time(NULL); struct tm *today = localtime(&today2); snprintf(filename, sizeof(filename), "vstats_%02d%02d%02d.log", today->tm_hour, today->tm_min, today->tm_sec); return opt_vstats_...
{ "code": [], "line_no": [] }
static int FUNC_0(void *VAR_0, const char *VAR_1, const char *VAR_2) { char VAR_3[40]; time_t today2 = time(NULL); struct tm *VAR_4 = localtime(&today2); snprintf(VAR_3, sizeof(VAR_3), "vstats_%02d%02d%02d.log", VAR_4->tm_hour, VAR_4->tm_min, VAR_4->tm_sec); return opt_vstats_file(NULL,...
[ "static int FUNC_0(void *VAR_0, const char *VAR_1, const char *VAR_2)\n{", "char VAR_3[40];", "time_t today2 = time(NULL);", "struct tm *VAR_4 = localtime(&today2);", "snprintf(VAR_3, sizeof(VAR_3), \"vstats_%02d%02d%02d.log\", VAR_4->tm_hour, VAR_4->tm_min,\nVAR_4->tm_sec);", "return opt_vstats_file(NULL...
[ 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 2 ], [ 3 ], [ 4 ], [ 5 ], [ 6, 7 ], [ 8 ], [ 9 ] ]
6,131
static void gen_brcond(DisasContext *dc, TCGCond cond, TCGv_i32 t0, TCGv_i32 t1, uint32_t offset) { int label = gen_new_label(); tcg_gen_brcond_i32(cond, t0, t1, label); gen_jumpi(dc, dc->next_pc, 0); gen_set_label(label); gen_jumpi(dc, dc->pc + offset, 1); }
true
qemu
797d780b1375b1af1d7713685589bfdec9908dc3
static void gen_brcond(DisasContext *dc, TCGCond cond, TCGv_i32 t0, TCGv_i32 t1, uint32_t offset) { int label = gen_new_label(); tcg_gen_brcond_i32(cond, t0, t1, label); gen_jumpi(dc, dc->next_pc, 0); gen_set_label(label); gen_jumpi(dc, dc->pc + offset, 1); }
{ "code": [ " gen_jumpi(dc, dc->next_pc, 0);" ], "line_no": [ 13 ] }
static void FUNC_0(DisasContext *VAR_0, TCGCond VAR_1, TCGv_i32 VAR_2, TCGv_i32 VAR_3, uint32_t VAR_4) { int VAR_5 = gen_new_label(); tcg_gen_brcond_i32(VAR_1, VAR_2, VAR_3, VAR_5); gen_jumpi(VAR_0, VAR_0->next_pc, 0); gen_set_label(VAR_5); gen_jumpi(VAR_0, VAR_0->pc + VAR_4, 1); }...
[ "static void FUNC_0(DisasContext *VAR_0, TCGCond VAR_1,\nTCGv_i32 VAR_2, TCGv_i32 VAR_3, uint32_t VAR_4)\n{", "int VAR_5 = gen_new_label();", "tcg_gen_brcond_i32(VAR_1, VAR_2, VAR_3, VAR_5);", "gen_jumpi(VAR_0, VAR_0->next_pc, 0);", "gen_set_label(VAR_5);", "gen_jumpi(VAR_0, VAR_0->pc + VAR_4, 1);", "}"...
[ 0, 0, 0, 1, 0, 0, 0 ]
[ [ 1, 3, 5 ], [ 7 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ] ]
6,132
void palette8tobgr24(const uint8_t *src, uint8_t *dst, unsigned num_pixels, const uint8_t *palette) { unsigned i; /* writes 1 byte o much and might cause alignment issues on some architectures? for(i=0; i<num_pixels; i++) ((unsigned *)(&dst[i*3])) = ((unsigned *)palette)[ src[i] ]; */ for(i=0; i<num_pixel...
true
FFmpeg
7f526efd17973ec6d2204f7a47b6923e2be31363
void palette8tobgr24(const uint8_t *src, uint8_t *dst, unsigned num_pixels, const uint8_t *palette) { unsigned i; for(i=0; i<num_pixels; i++) { dst[0]= palette[ src[i]*4+0 ]; dst[1]= palette[ src[i]*4+1 ]; dst[2]= palette[ src[i]*4+2 ]; dst+= 3; } }
{ "code": [ "\tunsigned i;", "\tunsigned i;", "\tunsigned i;", "void palette8tobgr24(const uint8_t *src, uint8_t *dst, unsigned num_pixels, const uint8_t *palette)", "\tunsigned i;", "\tunsigned i;", "\tunsigned i;", "\tunsigned i;", "\tunsigned i;", "\tunsigned i;", "\tuns...
void FUNC_0(const uint8_t *VAR_0, uint8_t *VAR_1, unsigned VAR_2, const uint8_t *VAR_3) { unsigned VAR_4; for(VAR_4=0; VAR_4<VAR_2; VAR_4++) { VAR_1[0]= VAR_3[ VAR_0[VAR_4]*4+0 ]; VAR_1[1]= VAR_3[ VAR_0[VAR_4]*4+1 ]; VAR_1[2]= VAR_3[ VAR_0[VAR_4]*4+2 ]; VAR_1+= 3; } }
[ "void FUNC_0(const uint8_t *VAR_0, uint8_t *VAR_1, unsigned VAR_2, const uint8_t *VAR_3)\n{", "unsigned VAR_4;", "for(VAR_4=0; VAR_4<VAR_2; VAR_4++)", "{", "VAR_1[0]= VAR_3[ VAR_0[VAR_4]*4+0 ];", "VAR_1[1]= VAR_3[ VAR_0[VAR_4]*4+1 ];", "VAR_1[2]= VAR_3[ VAR_0[VAR_4]*4+2 ];", "VAR_1+= 3;", "}", "}"...
[ 1, 1, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 17 ], [ 19 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ] ]
6,134
bool qpci_msix_pending(QPCIDevice *dev, uint16_t entry) { uint32_t pba_entry; uint8_t bit_n = entry % 32; void *addr = dev->msix_pba + (entry / 32) * PCI_MSIX_ENTRY_SIZE / 4; g_assert(dev->msix_enabled); pba_entry = qpci_io_readl(dev, addr); qpci_io_writel(dev, addr, pba_entry & ~(1 << ...
true
qemu
b4ba67d9a702507793c2724e56f98e9b0f7be02b
bool qpci_msix_pending(QPCIDevice *dev, uint16_t entry) { uint32_t pba_entry; uint8_t bit_n = entry % 32; void *addr = dev->msix_pba + (entry / 32) * PCI_MSIX_ENTRY_SIZE / 4; g_assert(dev->msix_enabled); pba_entry = qpci_io_readl(dev, addr); qpci_io_writel(dev, addr, pba_entry & ~(1 << ...
{ "code": [ " void *addr = dev->msix_pba + (entry / 32) * PCI_MSIX_ENTRY_SIZE / 4;", " pba_entry = qpci_io_readl(dev, addr);", " qpci_io_writel(dev, addr, pba_entry & ~(1 << bit_n));" ], "line_no": [ 9, 15, 17 ] }
bool FUNC_0(QPCIDevice *dev, uint16_t entry) { uint32_t pba_entry; uint8_t bit_n = entry % 32; void *VAR_0 = dev->msix_pba + (entry / 32) * PCI_MSIX_ENTRY_SIZE / 4; g_assert(dev->msix_enabled); pba_entry = qpci_io_readl(dev, VAR_0); qpci_io_writel(dev, VAR_0, pba_entry & ~(1 << bit_n));...
[ "bool FUNC_0(QPCIDevice *dev, uint16_t entry)\n{", "uint32_t pba_entry;", "uint8_t bit_n = entry % 32;", "void *VAR_0 = dev->msix_pba + (entry / 32) * PCI_MSIX_ENTRY_SIZE / 4;", "g_assert(dev->msix_enabled);", "pba_entry = qpci_io_readl(dev, VAR_0);", "qpci_io_writel(dev, VAR_0, pba_entry & ~(1 << bit_n...
[ 0, 0, 0, 1, 0, 1, 1, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ] ]
6,135
static void init_proc_750cx (CPUPPCState *env) { gen_spr_ne_601(env); gen_spr_7xx(env); /* XXX : not implemented */ spr_register(env, SPR_L2CR, "L2CR", SPR_NOACCESS, SPR_NOACCESS, &spr_read_generic, NULL, 0x00000000); /* Time base */ g...
true
qemu
9633fcc6a02f23e3ef00aa5fe3fe9c41f57c3456
static void init_proc_750cx (CPUPPCState *env) { gen_spr_ne_601(env); gen_spr_7xx(env); spr_register(env, SPR_L2CR, "L2CR", SPR_NOACCESS, SPR_NOACCESS, &spr_read_generic, NULL, 0x00000000); gen_tbl(env); gen_spr_thrm(env);...
{ "code": [ " &spr_read_generic, NULL,", " &spr_read_generic, NULL,", " &spr_read_generic, NULL,", " &spr_read_generic, NULL,", " &spr_read_generic, NULL,", " &spr_read_generic, NULL,", " ...
static void FUNC_0 (CPUPPCState *VAR_0) { gen_spr_ne_601(VAR_0); gen_spr_7xx(VAR_0); spr_register(VAR_0, SPR_L2CR, "L2CR", SPR_NOACCESS, SPR_NOACCESS, &spr_read_generic, NULL, 0x00000000); gen_tbl(VAR_0); gen_spr_thrm(VAR_...
[ "static void FUNC_0 (CPUPPCState *VAR_0)\n{", "gen_spr_ne_601(VAR_0);", "gen_spr_7xx(VAR_0);", "spr_register(VAR_0, SPR_L2CR, \"L2CR\",\nSPR_NOACCESS, SPR_NOACCESS,\n&spr_read_generic, NULL,\n0x00000000);", "gen_tbl(VAR_0);", "gen_spr_thrm(VAR_0);", "spr_register(VAR_0, SPR_SDA, \"SDA\",\nSPR_NOACCESS, ...
[ 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 11, 13, 15, 17 ], [ 21 ], [ 25 ], [ 29, 31, 33, 35 ], [ 41, 43, 45, 47 ], [ 51, 53, 55, 57 ], [ 61 ], [ 65 ], [ 67 ], [ 69 ], [ 71...
6,136
static int show_stream(WriterContext *w, AVFormatContext *fmt_ctx, int stream_idx, InputStream *ist, int in_program) { AVStream *stream = ist->st; AVCodecParameters *par; AVCodecContext *dec_ctx; char val_str[128]; const char *s; AVRational sar, dar; AVBPrint pbuf; const AVCodec...
true
FFmpeg
837cb4325b712ff1aab531bf41668933f61d75d2
static int show_stream(WriterContext *w, AVFormatContext *fmt_ctx, int stream_idx, InputStream *ist, int in_program) { AVStream *stream = ist->st; AVCodecParameters *par; AVCodecContext *dec_ctx; char val_str[128]; const char *s; AVRational sar, dar; AVBPrint pbuf; const AVCodec...
{ "code": [ " if (par->color_primaries != AVCOL_PRI_UNSPECIFIED)", " print_str(\"color_primaries\", av_color_primaries_name(par->color_primaries));", " print_str_opt(\"color_primaries\", av_color_primaries_name(par->color_primaries));" ], "line_no": [ 195, 197, ...
static int FUNC_0(WriterContext *VAR_0, AVFormatContext *VAR_1, int VAR_2, InputStream *VAR_3, int VAR_4) { AVStream *stream = VAR_3->st; AVCodecParameters *par; AVCodecContext *dec_ctx; char VAR_5[128]; const char *VAR_6; AVRational sar, dar; AVBPrint pbuf; const AVCodecDescrip...
[ "static int FUNC_0(WriterContext *VAR_0, AVFormatContext *VAR_1, int VAR_2, InputStream *VAR_3, int VAR_4)\n{", "AVStream *stream = VAR_3->st;", "AVCodecParameters *par;", "AVCodecContext *dec_ctx;", "char VAR_5[128];", "const char *VAR_6;", "AVRational sar, dar;", "AVBPrint pbuf;", "const AVCodecDe...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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 ], [ 31 ], [ 35 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ], [ 49,...
6,137
static void openpic_save_IRQ_queue(QEMUFile* f, IRQ_queue_t *q) { unsigned int i; for (i = 0; i < BF_WIDTH(MAX_IRQ); i++) qemu_put_be32s(f, &q->queue[i]); qemu_put_sbe32s(f, &q->next); qemu_put_sbe32s(f, &q->priority); }
true
qemu
af7e9e74c6a62a5bcd911726a9e88d28b61490e0
static void openpic_save_IRQ_queue(QEMUFile* f, IRQ_queue_t *q) { unsigned int i; for (i = 0; i < BF_WIDTH(MAX_IRQ); i++) qemu_put_be32s(f, &q->queue[i]); qemu_put_sbe32s(f, &q->next); qemu_put_sbe32s(f, &q->priority); }
{ "code": [ "static void openpic_save_IRQ_queue(QEMUFile* f, IRQ_queue_t *q)" ], "line_no": [ 1 ] }
static void FUNC_0(QEMUFile* VAR_0, IRQ_queue_t *VAR_1) { unsigned int VAR_2; for (VAR_2 = 0; VAR_2 < BF_WIDTH(MAX_IRQ); VAR_2++) qemu_put_be32s(VAR_0, &VAR_1->queue[VAR_2]); qemu_put_sbe32s(VAR_0, &VAR_1->next); qemu_put_sbe32s(VAR_0, &VAR_1->priority); }
[ "static void FUNC_0(QEMUFile* VAR_0, IRQ_queue_t *VAR_1)\n{", "unsigned int VAR_2;", "for (VAR_2 = 0; VAR_2 < BF_WIDTH(MAX_IRQ); VAR_2++)", "qemu_put_be32s(VAR_0, &VAR_1->queue[VAR_2]);", "qemu_put_sbe32s(VAR_0, &VAR_1->next);", "qemu_put_sbe32s(VAR_0, &VAR_1->priority);", "}" ]
[ 1, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 9 ], [ 11 ], [ 15 ], [ 17 ], [ 19 ] ]
6,138
static void qed_is_allocated_cb(void *opaque, int ret, uint64_t offset, size_t len) { QEDIsAllocatedCB *cb = opaque; BDRVQEDState *s = cb->bs->opaque; *cb->pnum = len / BDRV_SECTOR_SIZE; switch (ret) { case QED_CLUSTER_FOUND: offset |= qed_offset_into_cluster(s, cb->pos); cb-...
true
qemu
0b8b8753e4d94901627b3e86431230f2319215c4
static void qed_is_allocated_cb(void *opaque, int ret, uint64_t offset, size_t len) { QEDIsAllocatedCB *cb = opaque; BDRVQEDState *s = cb->bs->opaque; *cb->pnum = len / BDRV_SECTOR_SIZE; switch (ret) { case QED_CLUSTER_FOUND: offset |= qed_offset_into_cluster(s, cb->pos); cb-...
{ "code": [ " qemu_coroutine_enter(cb->co, NULL);", " qemu_coroutine_enter(cb->co, NULL);" ], "line_no": [ 51, 51 ] }
static void FUNC_0(void *VAR_0, int VAR_1, uint64_t VAR_2, size_t VAR_3) { QEDIsAllocatedCB *cb = VAR_0; BDRVQEDState *s = cb->bs->VAR_0; *cb->pnum = VAR_3 / BDRV_SECTOR_SIZE; switch (VAR_1) { case QED_CLUSTER_FOUND: VAR_2 |= qed_offset_into_cluster(s, cb->pos); cb->status = ...
[ "static void FUNC_0(void *VAR_0, int VAR_1, uint64_t VAR_2, size_t VAR_3)\n{", "QEDIsAllocatedCB *cb = VAR_0;", "BDRVQEDState *s = cb->bs->VAR_0;", "*cb->pnum = VAR_3 / BDRV_SECTOR_SIZE;", "switch (VAR_1) {", "case QED_CLUSTER_FOUND:\nVAR_2 |= qed_offset_into_cluster(s, cb->pos);", "cb->status = BDRV_BL...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13, 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23, 25 ], [ 27 ], [ 29, 31, 33 ], [ 35 ], [ 37, 39 ], [ 41 ], [ 43 ], [ 45 ], [...
6,139
static av_cold int ffat_close_decoder(AVCodecContext *avctx) { ATDecodeContext *at = avctx->priv_data; if (at->converter) AudioConverterDispose(at->converter); av_packet_unref(&at->new_in_pkt); av_packet_unref(&at->in_pkt); av_free(at->decoded_data); av_free(at->extradata); ...
false
FFmpeg
f4e593f7b51f7cb30986186c187cff939c82d86d
static av_cold int ffat_close_decoder(AVCodecContext *avctx) { ATDecodeContext *at = avctx->priv_data; if (at->converter) AudioConverterDispose(at->converter); av_packet_unref(&at->new_in_pkt); av_packet_unref(&at->in_pkt); av_free(at->decoded_data); av_free(at->extradata); ...
{ "code": [], "line_no": [] }
static av_cold int FUNC_0(AVCodecContext *avctx) { ATDecodeContext *at = avctx->priv_data; if (at->converter) AudioConverterDispose(at->converter); av_packet_unref(&at->new_in_pkt); av_packet_unref(&at->in_pkt); av_free(at->decoded_data); av_free(at->extradata); return 0; }...
[ "static av_cold int FUNC_0(AVCodecContext *avctx)\n{", "ATDecodeContext *at = avctx->priv_data;", "if (at->converter)\nAudioConverterDispose(at->converter);", "av_packet_unref(&at->new_in_pkt);", "av_packet_unref(&at->in_pkt);", "av_free(at->decoded_data);", "av_free(at->extradata);", "return 0;", "...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7, 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ] ]
6,141
static int rtsp_read_packet(AVFormatContext *s, AVPacket *pkt) { RTSPState *rt = s->priv_data; int ret; RTSPMessageHeader reply1, *reply = &reply1; char cmd[1024]; if (rt->server_type == RTSP_SERVER_REAL) { int i; enum AVDiscard cache[MAX_STREAMS]; for (i = 0; i ...
false
FFmpeg
be73ba2fa4890b857d987b79958e46af8c5e545b
static int rtsp_read_packet(AVFormatContext *s, AVPacket *pkt) { RTSPState *rt = s->priv_data; int ret; RTSPMessageHeader reply1, *reply = &reply1; char cmd[1024]; if (rt->server_type == RTSP_SERVER_REAL) { int i; enum AVDiscard cache[MAX_STREAMS]; for (i = 0; i ...
{ "code": [], "line_no": [] }
static int FUNC_0(AVFormatContext *VAR_0, AVPacket *VAR_1) { RTSPState *rt = VAR_0->priv_data; int VAR_2; RTSPMessageHeader reply1, *reply = &reply1; char VAR_3[1024]; if (rt->server_type == RTSP_SERVER_REAL) { int VAR_4; enum AVDiscard VAR_5[MAX_STREAMS]; for (V...
[ "static int FUNC_0(AVFormatContext *VAR_0, AVPacket *VAR_1)\n{", "RTSPState *rt = VAR_0->priv_data;", "int VAR_2;", "RTSPMessageHeader reply1, *reply = &reply1;", "char VAR_3[1024];", "if (rt->server_type == RTSP_SERVER_REAL) {", "int VAR_4;", "enum AVDiscard VAR_5[MAX_STREAMS];", "for (VAR_4 = 0; 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 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 15 ], [ 17 ], [ 19 ], [ 23 ], [ 25 ], [ 29 ], [ 31, 33 ], [ 35, 37, 39 ], [ 41, 43 ], [ 45, 47 ], [ 49 ], [ 51 ], [...
6,142
static void reset_contexts(SnowContext *s){ int plane_index, level, orientation; for(plane_index=0; plane_index<2; plane_index++){ for(level=0; level<s->spatial_decomposition_count; level++){ for(orientation=level ? 1:0; orientation<4; orientation++){ memset(s->plane[p...
false
FFmpeg
155ec6edf82692bcf3a5f87d2bc697404f4e5aaf
static void reset_contexts(SnowContext *s){ int plane_index, level, orientation; for(plane_index=0; plane_index<2; plane_index++){ for(level=0; level<s->spatial_decomposition_count; level++){ for(orientation=level ? 1:0; orientation<4; orientation++){ memset(s->plane[p...
{ "code": [], "line_no": [] }
static void FUNC_0(SnowContext *VAR_0){ int VAR_1, VAR_2, VAR_3; for(VAR_1=0; VAR_1<2; VAR_1++){ for(VAR_2=0; VAR_2<VAR_0->spatial_decomposition_count; VAR_2++){ for(VAR_3=VAR_2 ? 1:0; VAR_3<4; VAR_3++){ memset(VAR_0->plane[VAR_1].band[VAR_2][VAR_3].state, 0, sizeof(VA...
[ "static void FUNC_0(SnowContext *VAR_0){", "int VAR_1, VAR_2, VAR_3;", "for(VAR_1=0; VAR_1<2; VAR_1++){", "for(VAR_2=0; VAR_2<VAR_0->spatial_decomposition_count; VAR_2++){", "for(VAR_3=VAR_2 ? 1:0; VAR_3<4; VAR_3++){", "memset(VAR_0->plane[VAR_1].band[VAR_2][VAR_3].state, 0, sizeof(VAR_0->plane[VAR_1].ban...
[ 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 ] ]
6,143
static int encode_frame(AVCodecContext* avc_context, uint8_t *outbuf, int buf_size, void *data) { th_ycbcr_buffer t_yuv_buffer; TheoraContext *h = avc_context->priv_data; AVFrame *frame = data; ogg_packet o_packet; int result, i; // EOS, finish and get 1st pass ...
false
FFmpeg
a4914ac70880784d0e9bee814afac1235d1cd92b
static int encode_frame(AVCodecContext* avc_context, uint8_t *outbuf, int buf_size, void *data) { th_ycbcr_buffer t_yuv_buffer; TheoraContext *h = avc_context->priv_data; AVFrame *frame = data; ogg_packet o_packet; int result, i; if (!frame) { th_...
{ "code": [], "line_no": [] }
static int FUNC_0(AVCodecContext* VAR_0, uint8_t *VAR_1, int VAR_2, void *VAR_3) { th_ycbcr_buffer t_yuv_buffer; TheoraContext *h = VAR_0->priv_data; AVFrame *frame = VAR_3; ogg_packet o_packet; int VAR_4, VAR_5; if (!frame) { th_encode_packetout(...
[ "static int FUNC_0(AVCodecContext* VAR_0, uint8_t *VAR_1,\nint VAR_2, void *VAR_3)\n{", "th_ycbcr_buffer t_yuv_buffer;", "TheoraContext *h = VAR_0->priv_data;", "AVFrame *frame = VAR_3;", "ogg_packet o_packet;", "int VAR_4, VAR_5;", "if (!frame) {", "th_encode_packetout(h->t_state, 1, &o_packet);", ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 21 ], [ 23 ], [ 25, 27, 29 ], [ 31 ], [ 33 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ], [ 49 ], [ 53, 55,...
6,144
static int ipvideo_decode_block_opcode_0xF(IpvideoContext *s) { int x, y; unsigned char sample[2]; /* dithered encoding */ CHECK_STREAM_PTR(2); sample[0] = *s->stream_ptr++; sample[1] = *s->stream_ptr++; for (y = 0; y < 8; y++) { for (x = 0; x < 8; x += 2) { ...
false
FFmpeg
80ca19f766aea8f4724aac1b3faa772d25163c8a
static int ipvideo_decode_block_opcode_0xF(IpvideoContext *s) { int x, y; unsigned char sample[2]; CHECK_STREAM_PTR(2); sample[0] = *s->stream_ptr++; sample[1] = *s->stream_ptr++; for (y = 0; y < 8; y++) { for (x = 0; x < 8; x += 2) { *s->pixel_ptr++ = samp...
{ "code": [], "line_no": [] }
static int FUNC_0(IpvideoContext *VAR_0) { int VAR_1, VAR_2; unsigned char VAR_3[2]; CHECK_STREAM_PTR(2); VAR_3[0] = *VAR_0->stream_ptr++; VAR_3[1] = *VAR_0->stream_ptr++; for (VAR_2 = 0; VAR_2 < 8; VAR_2++) { for (VAR_1 = 0; VAR_1 < 8; VAR_1 += 2) { *VAR_0...
[ "static int FUNC_0(IpvideoContext *VAR_0)\n{", "int VAR_1, VAR_2;", "unsigned char VAR_3[2];", "CHECK_STREAM_PTR(2);", "VAR_3[0] = *VAR_0->stream_ptr++;", "VAR_3[1] = *VAR_0->stream_ptr++;", "for (VAR_2 = 0; VAR_2 < 8; VAR_2++) {", "for (VAR_1 = 0; VAR_1 < 8; VAR_1 += 2) {", "*VAR_0->pixel_ptr++ = V...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 13 ], [ 15 ], [ 17 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 39 ], [ 41 ] ]
6,145
static int compand_delay(AVFilterContext *ctx, AVFrame *frame) { CompandContext *s = ctx->priv; AVFilterLink *inlink = ctx->inputs[0]; const int channels = inlink->channels; const int nb_samples = frame->nb_samples; int chan, i, av_uninit(dindex), oindex, av_uninit(count); AVFrame *out_fr...
true
FFmpeg
709746b6affb5c87aee0c3b8ddb0a078453c6162
static int compand_delay(AVFilterContext *ctx, AVFrame *frame) { CompandContext *s = ctx->priv; AVFilterLink *inlink = ctx->inputs[0]; const int channels = inlink->channels; const int nb_samples = frame->nb_samples; int chan, i, av_uninit(dindex), oindex, av_uninit(count); AVFrame *out_fr...
{ "code": [ " if (!out_frame)" ], "line_no": [ 53 ] }
static int FUNC_0(AVFilterContext *VAR_0, AVFrame *VAR_1) { CompandContext *s = VAR_0->priv; AVFilterLink *inlink = VAR_0->inputs[0]; const int VAR_2 = inlink->VAR_2; const int VAR_3 = VAR_1->VAR_3; int VAR_4, VAR_5, FUNC_1(dindex), oindex, FUNC_1(count); AVFrame *out_frame = NULL; ...
[ "static int FUNC_0(AVFilterContext *VAR_0, AVFrame *VAR_1)\n{", "CompandContext *s = VAR_0->priv;", "AVFilterLink *inlink = VAR_0->inputs[0];", "const int VAR_2 = inlink->VAR_2;", "const int VAR_3 = VAR_1->VAR_3;", "int VAR_4, VAR_5, FUNC_1(dindex), oindex, FUNC_1(count);", "AVFrame *out_frame = NULL;",...
[ 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 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 19 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 47 ], [ 49 ...
6,146
static void vga_reset(void *opaque) { VGAState *s = (VGAState *) opaque; s->lfb_addr = 0; s->lfb_end = 0; s->map_addr = 0; s->map_end = 0; s->lfb_vram_mapped = 0; s->bios_offset = 0; s->bios_size = 0; s->sr_index = 0; memset(s->sr, '\0', sizeof(s->sr)); s->gr_in...
true
qemu
4abc796d41ee01a698032e74ac17c1cdc5d290c3
static void vga_reset(void *opaque) { VGAState *s = (VGAState *) opaque; s->lfb_addr = 0; s->lfb_end = 0; s->map_addr = 0; s->map_end = 0; s->lfb_vram_mapped = 0; s->bios_offset = 0; s->bios_size = 0; s->sr_index = 0; memset(s->sr, '\0', sizeof(s->sr)); s->gr_in...
{ "code": [ "static void vga_reset(void *opaque)" ], "line_no": [ 1 ] }
static void FUNC_0(void *VAR_0) { VGAState *s = (VGAState *) VAR_0; s->lfb_addr = 0; s->lfb_end = 0; s->map_addr = 0; s->map_end = 0; s->lfb_vram_mapped = 0; s->bios_offset = 0; s->bios_size = 0; s->sr_index = 0; memset(s->sr, '\0', sizeof(s->sr)); s->gr_index =...
[ "static void FUNC_0(void *VAR_0)\n{", "VGAState *s = (VGAState *) VAR_0;", "s->lfb_addr = 0;", "s->lfb_end = 0;", "s->map_addr = 0;", "s->map_end = 0;", "s->lfb_vram_mapped = 0;", "s->bios_offset = 0;", "s->bios_size = 0;", "s->sr_index = 0;", "memset(s->sr, '\\0', sizeof(s->sr));", "s->gr_ind...
[ 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 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43...
6,147
vu_queue_pop(VuDev *dev, VuVirtq *vq, size_t sz) { unsigned int i, head, max; VuVirtqElement *elem; unsigned out_num, in_num; struct iovec iov[VIRTQUEUE_MAX_SIZE]; struct vring_desc *desc; int rc; if (unlikely(dev->broken)) { return NULL; } if (vu_queue_empty(d...
true
qemu
640601c7cb1b6b41d3e1a435b986266c2b71e9bc
vu_queue_pop(VuDev *dev, VuVirtq *vq, size_t sz) { unsigned int i, head, max; VuVirtqElement *elem; unsigned out_num, in_num; struct iovec iov[VIRTQUEUE_MAX_SIZE]; struct vring_desc *desc; int rc; if (unlikely(dev->broken)) { return NULL; } if (vu_queue_empty(d...
{ "code": [ " if (unlikely(dev->broken)) {", " if (unlikely(dev->broken)) {", " if (unlikely(dev->broken)) {", " if (unlikely(dev->broken)) {" ], "line_no": [ 19, 19, 19, 19 ] }
FUNC_0(VuDev *VAR_0, VuVirtq *VAR_1, size_t VAR_2) { unsigned int VAR_3, VAR_4, VAR_5; VuVirtqElement *elem; unsigned VAR_6, VAR_7; struct iovec VAR_8[VIRTQUEUE_MAX_SIZE]; struct vring_desc *VAR_9; int VAR_10; if (unlikely(VAR_0->broken)) { return NULL; } if (v...
[ "FUNC_0(VuDev *VAR_0, VuVirtq *VAR_1, size_t VAR_2)\n{", "unsigned int VAR_3, VAR_4, VAR_5;", "VuVirtqElement *elem;", "unsigned VAR_6, VAR_7;", "struct iovec VAR_8[VIRTQUEUE_MAX_SIZE];", "struct vring_desc *VAR_9;", "int VAR_10;", "if (unlikely(VAR_0->broken)) {", "return NULL;", "}", "if (vu_q...
[ 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 ], [ 19 ], [ 21 ], [ 23 ], [ 27 ], [ 29 ], [ 31 ], [ 37 ], [ 43 ], [ 47 ], [ 49 ], [ 51 ], [ 53 ], [ 55 ...
6,148
static void rtas_read_pci_config(sPAPREnvironment *spapr, uint32_t token, uint32_t nargs, target_ulong args, uint32_t nret, target_ulong rets) { uint32_t val, size, addr; PCIDevice *dev = find_dev(spapr, 0, ...
true
qemu
c9c3c80af71dd2b7813d1ada9b14cb51df584221
static void rtas_read_pci_config(sPAPREnvironment *spapr, uint32_t token, uint32_t nargs, target_ulong args, uint32_t nret, target_ulong rets) { uint32_t val, size, addr; PCIDevice *dev = find_dev(spapr, 0, ...
{ "code": [ " val = pci_default_read_config(dev, addr, size);", " val = pci_default_read_config(dev, addr, size);" ], "line_no": [ 29, 29 ] }
static void FUNC_0(sPAPREnvironment *VAR_0, uint32_t VAR_1, uint32_t VAR_2, target_ulong VAR_3, uint32_t VAR_4, target_ulong VAR_5) { uint32_t val, size, addr; PCIDevice *dev = find_dev(VAR_0, 0, rtas_ld(VAR...
[ "static void FUNC_0(sPAPREnvironment *VAR_0,\nuint32_t VAR_1, uint32_t VAR_2,\ntarget_ulong VAR_3,\nuint32_t VAR_4, target_ulong VAR_5)\n{", "uint32_t val, size, addr;", "PCIDevice *dev = find_dev(VAR_0, 0, rtas_ld(VAR_3, 0));", "if (!dev) {", "rtas_st(VAR_5, 0, -1);", "return;", "}", "size = rtas_ld(...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0 ]
[ [ 1, 3, 5, 7, 9 ], [ 11 ], [ 13 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ] ]
6,149
static inline void RENAME(hyscale)(SwsContext *c, uint16_t *dst, int dstWidth, const uint8_t *src, int srcW, int xInc, const int16_t *hLumFilter, const int16_t *hLumFilterPos, int hLumFilterSize, uint8_t *formatC...
true
FFmpeg
c3ab0004ae4dffc32494ae84dd15cfaa909a7884
static inline void RENAME(hyscale)(SwsContext *c, uint16_t *dst, int dstWidth, const uint8_t *src, int srcW, int xInc, const int16_t *hLumFilter, const int16_t *hLumFilterPos, int hLumFilterSize, uint8_t *formatC...
{ "code": [ "static inline void RENAME(hyscale)(SwsContext *c, uint16_t *dst, int dstWidth, const uint8_t *src, int srcW, int xInc,", " void (*toYV12)(uint8_t *, const uint8_t *, int, uint32_t *) = isAlpha ? c->alpToYV12 : c->lumToYV12;" ], "line_no": [ 1, 13 ] }
VAR_3staticVAR_3 VAR_3inlineVAR_3 VAR_3voidVAR_3 VAR_3RENAMEVAR_3(VAR_3hyscaleVAR_3)(VAR_3SwsContextVAR_3 *VAR_3cVAR_3, VAR_3uint16_tVAR_3 *VAR_3dstVAR_3, VAR_3intVAR_3 VAR_3dstWidthVAR_3, VAR_3constVAR_3 VAR_3uint8_tVAR_3 *VAR_3srcVAR_3, VAR_3intVAR_3 VAR_3srcWVAR_3, VAR_3intVAR_3 VAR_3xIncVAR_3, ...
[ "VAR_3staticVAR_3 VAR_3inlineVAR_3 VAR_3voidVAR_3 VAR_3RENAMEVAR_3(VAR_3hyscaleVAR_3)(VAR_3SwsContextVAR_3 *VAR_3cVAR_3, VAR_3uint16_tVAR_3 *VAR_3dstVAR_3, VAR_3intVAR_3 VAR_3dstWidthVAR_3, VAR_3constVAR_3 VAR_3uint8_tVAR_3 *VAR_3srcVAR_3, VAR_3intVAR_3 VAR_3srcWVAR_3, VAR_3intVAR_3 VAR_3xIncVAR_3,\nVAR_3constVAR_3...
[ 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5, 7, 9, 11 ], [ 13 ], [ 15 ], [ 19 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 45, 47 ], [ 49 ] ]
6,150
static int dxtory_decode_v2(AVCodecContext *avctx, AVFrame *pic, const uint8_t *src, int src_size) { GetByteContext gb; GetBitContext gb2; int nslices, slice, slice_height, ref_slice_height; int cur_y, next_y; uint32_t off, slice_size; uint8_t *Y, *U, *V; ...
true
FFmpeg
025fd76e1a2623c858d8c686a73cc30980a314b0
static int dxtory_decode_v2(AVCodecContext *avctx, AVFrame *pic, const uint8_t *src, int src_size) { GetByteContext gb; GetBitContext gb2; int nslices, slice, slice_height, ref_slice_height; int cur_y, next_y; uint32_t off, slice_size; uint8_t *Y, *U, *V; ...
{ "code": [ " return AVERROR(ENOSYS);" ], "line_no": [ 45 ] }
static int FUNC_0(AVCodecContext *VAR_0, AVFrame *VAR_1, const uint8_t *VAR_2, int VAR_3) { GetByteContext gb; GetBitContext gb2; int VAR_4, VAR_5, VAR_6, VAR_7; int VAR_8, VAR_9; uint32_t off, slice_size; uint8_t *Y, *U, *V; int VAR_10; bytestrea...
[ "static int FUNC_0(AVCodecContext *VAR_0, AVFrame *VAR_1,\nconst uint8_t *VAR_2, int VAR_3)\n{", "GetByteContext gb;", "GetBitContext gb2;", "int VAR_4, VAR_5, VAR_6, VAR_7;", "int VAR_8, VAR_9;", "uint32_t off, slice_size;", "uint8_t *Y, *U, *V;", "int VAR_10;", "bytestream2_init(&gb, VAR_2, VAR_3...
[ 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 ]
[ [ 1, 3, 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 39 ], [ 41, 43 ], [ 45 ], [ 47 ...
6,151
static int decode_packet(AVCodecContext *avctx, void *data, int *got_frame_ptr, AVPacket* avpkt) { WMAProDecodeCtx *s = avctx->priv_data; GetBitContext* gb = &s->pgb; const uint8_t* buf = avpkt->data; int buf_size = avpkt->size; int num_bits_prev_frame; in...
true
FFmpeg
c7a7605656633e52ade8a5d32a7c2497b37faef8
static int decode_packet(AVCodecContext *avctx, void *data, int *got_frame_ptr, AVPacket* avpkt) { WMAProDecodeCtx *s = avctx->priv_data; GetBitContext* gb = &s->pgb; const uint8_t* buf = avpkt->data; int buf_size = avpkt->size; int num_bits_prev_frame; in...
{ "code": [ " s->packet_done = !decode_frame(s, data, got_frame_ptr);" ], "line_no": [ 167 ] }
static int FUNC_0(AVCodecContext *VAR_0, void *VAR_1, int *VAR_2, AVPacket* VAR_3) { WMAProDecodeCtx *s = VAR_0->priv_data; GetBitContext* gb = &s->pgb; const uint8_t* VAR_4 = VAR_3->VAR_1; int VAR_5 = VAR_3->size; int VAR_6; int VAR_7; *VAR_2 = 0; ...
[ "static int FUNC_0(AVCodecContext *VAR_0, void *VAR_1,\nint *VAR_2, AVPacket* VAR_3)\n{", "WMAProDecodeCtx *s = VAR_0->priv_data;", "GetBitContext* gb = &s->pgb;", "const uint8_t* VAR_4 = VAR_3->VAR_1;", "int VAR_5 = VAR_3->size;", "int VAR_6;", "int VAR_7;", "*VAR_2 = 0;", "if (s->packet_don...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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, 3, 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 21 ], [ 25 ], [ 27 ], [ 33 ], [ 35, 37 ], [ 39 ], [ 41 ], [ 45 ], [ 47 ], [ 49 ], [ 55 ], [ 57 ...
6,152
static int qpa_init_out (HWVoiceOut *hw, struct audsettings *as) { int error; static pa_sample_spec ss; static pa_buffer_attr ba; struct audsettings obt_as = *as; PAVoiceOut *pa = (PAVoiceOut *) hw; ss.format = audfmt_to_pa (as->fmt, as->endianness); ss.channels = as->nchannels; ...
true
qemu
ea9ebc2ce69198f7aca4b43652824c5d621ac978
static int qpa_init_out (HWVoiceOut *hw, struct audsettings *as) { int error; static pa_sample_spec ss; static pa_buffer_attr ba; struct audsettings obt_as = *as; PAVoiceOut *pa = (PAVoiceOut *) hw; ss.format = audfmt_to_pa (as->fmt, as->endianness); ss.channels = as->nchannels; ...
{ "code": [ " pa->s = pa_simple_new (", " conf.server,", " conf.sink,", " if (!pa->s) {", " hw->samples = conf.samples;", " pa_simple_free (pa->s);", " pa->s = NULL;", " pa->s = pa_simple_new (", " conf.server,", " if (!pa->s) {", "...
static int FUNC_0 (HWVoiceOut *VAR_0, struct audsettings *VAR_1) { int VAR_2; static pa_sample_spec VAR_3; static pa_buffer_attr VAR_4; struct audsettings VAR_5 = *VAR_1; PAVoiceOut *pa = (PAVoiceOut *) VAR_0; VAR_3.format = audfmt_to_pa (VAR_1->fmt, VAR_1->endianness); VAR_3.chann...
[ "static int FUNC_0 (HWVoiceOut *VAR_0, struct audsettings *VAR_1)\n{", "int VAR_2;", "static pa_sample_spec VAR_3;", "static pa_buffer_attr VAR_4;", "struct audsettings VAR_5 = *VAR_1;", "PAVoiceOut *pa = (PAVoiceOut *) VAR_0;", "VAR_3.format = audfmt_to_pa (VAR_1->fmt, VAR_1->endianness);", "VAR_3.ch...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 17 ], [ 19 ], [ 21 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 43 ], [ 47, 49, 51, 53, 55, 57, 59, 61, 63, 65, 67 ...
6,154
static int qemu_rbd_open(BlockDriverState *bs, QDict *options, int flags, Error **errp) { BDRVRBDState *s = bs->opaque; char pool[RBD_MAX_POOL_NAME_SIZE]; char snap_buf[RBD_MAX_SNAP_NAME_SIZE]; char conf[RBD_MAX_CONF_SIZE]; char clientname_buf[RBD_MAX_CONF_SIZE]; ...
true
qemu
9281dbe6535d79ecae121f6c3e620c25d55230e9
static int qemu_rbd_open(BlockDriverState *bs, QDict *options, int flags, Error **errp) { BDRVRBDState *s = bs->opaque; char pool[RBD_MAX_POOL_NAME_SIZE]; char snap_buf[RBD_MAX_SNAP_NAME_SIZE]; char conf[RBD_MAX_CONF_SIZE]; char clientname_buf[RBD_MAX_CONF_SIZE]; ...
{ "code": [ " error_setg(&local_err, \"error initializing\");", " error_setg(&local_err, \"error connecting\");", " error_setg(&local_err, \"error opening pool %s\", pool);", " error_setg(&local_err, \"error reading header from %s\", s->name);" ], "line_no": [ 71, ...
static int FUNC_0(BlockDriverState *VAR_0, QDict *VAR_1, int VAR_2, Error **VAR_3) { BDRVRBDState *s = VAR_0->opaque; char VAR_4[RBD_MAX_POOL_NAME_SIZE]; char VAR_5[RBD_MAX_SNAP_NAME_SIZE]; char VAR_6[RBD_MAX_CONF_SIZE]; char VAR_7[RBD_MAX_CONF_SIZE]; char *VAR_8...
[ "static int FUNC_0(BlockDriverState *VAR_0, QDict *VAR_1, int VAR_2,\nError **VAR_3)\n{", "BDRVRBDState *s = VAR_0->opaque;", "char VAR_4[RBD_MAX_POOL_NAME_SIZE];", "char VAR_5[RBD_MAX_SNAP_NAME_SIZE];", "char VAR_6[RBD_MAX_CONF_SIZE];", "char VAR_7[RBD_MAX_CONF_SIZE];", "char *VAR_8;", "QemuOpts *opt...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0...
[ [ 1, 3, 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 45 ], [...
6,156
static void co_schedule_bh_cb(void *opaque) { AioContext *ctx = opaque; QSLIST_HEAD(, Coroutine) straight, reversed; QSLIST_MOVE_ATOMIC(&reversed, &ctx->scheduled_coroutines); QSLIST_INIT(&straight); while (!QSLIST_EMPTY(&reversed)) { Coroutine *co = QSLIST_FIRST(&reversed); QSLIST_R...
true
qemu
6133b39f3c36623425a6ede9e89d93175fde15cd
static void co_schedule_bh_cb(void *opaque) { AioContext *ctx = opaque; QSLIST_HEAD(, Coroutine) straight, reversed; QSLIST_MOVE_ATOMIC(&reversed, &ctx->scheduled_coroutines); QSLIST_INIT(&straight); while (!QSLIST_EMPTY(&reversed)) { Coroutine *co = QSLIST_FIRST(&reversed); QSLIST_R...
{ "code": [], "line_no": [] }
static void FUNC_0(void *VAR_0) { AioContext *ctx = VAR_0; QSLIST_HEAD(, Coroutine) straight, reversed; QSLIST_MOVE_ATOMIC(&reversed, &ctx->scheduled_coroutines); QSLIST_INIT(&straight); while (!QSLIST_EMPTY(&reversed)) { Coroutine *co = QSLIST_FIRST(&reversed); QSLIST_REMOVE_HEAD(&r...
[ "static void FUNC_0(void *VAR_0)\n{", "AioContext *ctx = VAR_0;", "QSLIST_HEAD(, Coroutine) straight, reversed;", "QSLIST_MOVE_ATOMIC(&reversed, &ctx->scheduled_coroutines);", "QSLIST_INIT(&straight);", "while (!QSLIST_EMPTY(&reversed)) {", "Coroutine *co = QSLIST_FIRST(&reversed);", "QSLIST_REMOVE_HE...
[ 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 ] ]
6,157
static int http_connect(URLContext *h, const char *path, const char *local_path, const char *hoststr, const char *auth, const char *proxyauth, int *new_location) { HTTPContext *s = h->priv_data; int post, err; char headers[1024] = ""; char *authstr ...
true
FFmpeg
71549a857b13edf4c4f95037de6ed5bb4c4bd4af
static int http_connect(URLContext *h, const char *path, const char *local_path, const char *hoststr, const char *auth, const char *proxyauth, int *new_location) { HTTPContext *s = h->priv_data; int post, err; char headers[1024] = ""; char *authstr ...
{ "code": [ " if (post && !s->post_data) {" ], "line_no": [ 187 ] }
static int FUNC_0(URLContext *VAR_0, const char *VAR_1, const char *VAR_2, const char *VAR_3, const char *VAR_4, const char *VAR_5, int *VAR_6) { HTTPContext *s = VAR_0->priv_data; int VAR_7, VAR_8; char VAR_9[1024] = ""; char *VAR_10 = NULL, *VAR_1...
[ "static int FUNC_0(URLContext *VAR_0, const char *VAR_1, const char *VAR_2,\nconst char *VAR_3, const char *VAR_4,\nconst char *VAR_5, int *VAR_6)\n{", "HTTPContext *s = VAR_0->priv_data;", "int VAR_7, VAR_8;", "char VAR_9[1024] = \"\";", "char *VAR_10 = NULL, *VAR_11 = NULL;", "int64_t off = s->off;", ...
[ 0, 0, 0, 0, 0, 0, 0, 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 ]
[ [ 1, 3, 5, 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 29 ], [ 33 ], [ 39 ], [ 41 ], [ 43 ], [ 47 ], [ 49, 51 ], [ 53, 55 ], [ 61, 63, 65 ...
6,159
static void virtio_serial_class_init(ObjectClass *klass, void *data) { DeviceClass *dc = DEVICE_CLASS(klass); VirtioDeviceClass *vdc = VIRTIO_DEVICE_CLASS(klass); dc->exit = virtio_serial_device_exit; dc->props = virtio_serial_properties; set_bit(DEVICE_CATEGORY_INPUT, dc->categories); vd...
true
qemu
0e86c13fe2058adb8c792ebb7c51a6a7ca9d3d55
static void virtio_serial_class_init(ObjectClass *klass, void *data) { DeviceClass *dc = DEVICE_CLASS(klass); VirtioDeviceClass *vdc = VIRTIO_DEVICE_CLASS(klass); dc->exit = virtio_serial_device_exit; dc->props = virtio_serial_properties; set_bit(DEVICE_CATEGORY_INPUT, dc->categories); vd...
{ "code": [ " dc->exit = virtio_serial_device_exit;" ], "line_no": [ 9 ] }
static void FUNC_0(ObjectClass *VAR_0, void *VAR_1) { DeviceClass *dc = DEVICE_CLASS(VAR_0); VirtioDeviceClass *vdc = VIRTIO_DEVICE_CLASS(VAR_0); dc->exit = virtio_serial_device_exit; dc->props = virtio_serial_properties; set_bit(DEVICE_CATEGORY_INPUT, dc->categories); vdc->init = virtio_...
[ "static void FUNC_0(ObjectClass *VAR_0, void *VAR_1)\n{", "DeviceClass *dc = DEVICE_CLASS(VAR_0);", "VirtioDeviceClass *vdc = VIRTIO_DEVICE_CLASS(VAR_0);", "dc->exit = virtio_serial_device_exit;", "dc->props = virtio_serial_properties;", "set_bit(DEVICE_CATEGORY_INPUT, dc->categories);", "vdc->init = vi...
[ 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ] ]
6,161
static uint64_t get_channel_layout_single(const char *name, int name_len) { int i; char *end; int64_t layout; for (i = 0; i < FF_ARRAY_ELEMS(channel_layout_map); i++) { if (strlen(channel_layout_map[i].name) == name_len && !memcmp(channel_layout_map[i].name, name, name_len))...
true
FFmpeg
c9bfd6a8c35a2102e730aca12f6e09d1627f76b3
static uint64_t get_channel_layout_single(const char *name, int name_len) { int i; char *end; int64_t layout; for (i = 0; i < FF_ARRAY_ELEMS(channel_layout_map); i++) { if (strlen(channel_layout_map[i].name) == name_len && !memcmp(channel_layout_map[i].name, name, name_len))...
{ "code": [ " if ((end + 1 - name == name_len && *end == 'c'))", " if (end - name == name_len)" ], "line_no": [ 37, 45 ] }
static uint64_t FUNC_0(const char *name, int name_len) { int VAR_0; char *VAR_1; int64_t layout; for (VAR_0 = 0; VAR_0 < FF_ARRAY_ELEMS(channel_layout_map); VAR_0++) { if (strlen(channel_layout_map[VAR_0].name) == name_len && !memcmp(channel_layout_map[VAR_0].name, name, nam...
[ "static uint64_t FUNC_0(const char *name, int name_len)\n{", "int VAR_0;", "char *VAR_1;", "int64_t layout;", "for (VAR_0 = 0; VAR_0 < FF_ARRAY_ELEMS(channel_layout_map); VAR_0++) {", "if (strlen(channel_layout_map[VAR_0].name) == name_len &&\n!memcmp(channel_layout_map[VAR_0].name, name, name_len))\nretu...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 13 ], [ 15, 17, 19 ], [ 21 ], [ 23 ], [ 25, 27, 29, 31 ], [ 33 ], [ 37, 39 ], [ 43 ], [ 45, 47 ], [ 49 ], [ 51 ] ]
6,162
static void get_offset_range(hwaddr phys_addr, ram_addr_t mapping_length, DumpState *s, hwaddr *p_offset, hwaddr *p_filesz) { RAMBlock *block; hwaddr offset = s->memory_offset; int64_t...
true
qemu
56c4bfb3f07f3107894c00281276aea4f5e8834d
static void get_offset_range(hwaddr phys_addr, ram_addr_t mapping_length, DumpState *s, hwaddr *p_offset, hwaddr *p_filesz) { RAMBlock *block; hwaddr offset = s->memory_offset; int64_t...
{ "code": [ " RAMBlock *block;", " RAMBlock *block;", " QTAILQ_FOREACH(block, &ram_list.blocks, next) {", " if (block->offset >= s->begin + s->length ||", " block->offset + block->length <= s->begin) {", " if (s->begin <= block->offset) {", " ...
static void FUNC_0(hwaddr VAR_0, ram_addr_t VAR_1, DumpState *VAR_2, hwaddr *VAR_3, hwaddr *VAR_4) { RAMBlock *block; hwaddr offset = VAR_2->memory_offset; int64_t size_in_block, start...
[ "static void FUNC_0(hwaddr VAR_0,\nram_addr_t VAR_1,\nDumpState *VAR_2,\nhwaddr *VAR_3,\nhwaddr *VAR_4)\n{", "RAMBlock *block;", "hwaddr offset = VAR_2->memory_offset;", "int64_t size_in_block, start;", "*VAR_3 = -1;", "*VAR_4 = 0;", "if (VAR_2->has_filter) {", "if (VAR_0 < VAR_2->begin || VAR_0 >= VA...
[ 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 1, 1, 0, 0, 0, 1, 1, 1, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5, 7, 9, 11 ], [ 13 ], [ 15 ], [ 17 ], [ 23 ], [ 25 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 41 ], [ 43 ], [ 45, 47 ], [ 51 ], [ 53 ], [ 57 ], [...
6,163
static int qcow2_update_options(BlockDriverState *bs, QDict *options, int flags, Error **errp) { BDRVQcow2State *s = bs->opaque; QemuOpts *opts = NULL; const char *opt_overlap_check, *opt_overlap_check_template; int overlap_check_template = 0; uint64_t l2_cache...
true
qemu
c1344ded70cf7d471aeb6fc08134997414631811
static int qcow2_update_options(BlockDriverState *bs, QDict *options, int flags, Error **errp) { BDRVQcow2State *s = bs->opaque; QemuOpts *opts = NULL; const char *opt_overlap_check, *opt_overlap_check_template; int overlap_check_template = 0; uint64_t l2_cache...
{ "code": [ " Qcow2Cache *l2_table_cache;", " Qcow2Cache *refcount_block_cache;" ], "line_no": [ 17, 19 ] }
static int FUNC_0(BlockDriverState *VAR_0, QDict *VAR_1, int VAR_2, Error **VAR_3) { BDRVQcow2State *s = VAR_0->opaque; QemuOpts *opts = NULL; const char *VAR_4, *VAR_5; int VAR_6 = 0; uint64_t l2_cache_size, refcount_cache_size; Qcow2Cache *l2_table_cache...
[ "static int FUNC_0(BlockDriverState *VAR_0, QDict *VAR_1,\nint VAR_2, Error **VAR_3)\n{", "BDRVQcow2State *s = VAR_0->opaque;", "QemuOpts *opts = NULL;", "const char *VAR_4, *VAR_5;", "int VAR_6 = 0;", "uint64_t l2_cache_size, refcount_cache_size;", "Qcow2Cache *l2_table_cache;", "Qcow2Cache *refcount...
[ 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ [ 1, 3, 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [...
6,164
vu_message_read(VuDev *dev, int conn_fd, VhostUserMsg *vmsg) { char control[CMSG_SPACE(VHOST_MEMORY_MAX_NREGIONS * sizeof(int))] = { }; struct iovec iov = { .iov_base = (char *)vmsg, .iov_len = VHOST_USER_HDR_SIZE, }; struct msghdr msg = { .msg_iov = &iov, .msg_i...
true
qemu
2566378d6d13bf4d28c7770bdbda5f7682594bbe
vu_message_read(VuDev *dev, int conn_fd, VhostUserMsg *vmsg) { char control[CMSG_SPACE(VHOST_MEMORY_MAX_NREGIONS * sizeof(int))] = { }; struct iovec iov = { .iov_base = (char *)vmsg, .iov_len = VHOST_USER_HDR_SIZE, }; struct msghdr msg = { .msg_iov = &iov, .msg_i...
{ "code": [ " if (rc <= 0) {" ], "line_no": [ 43 ] }
FUNC_0(VuDev *VAR_0, int VAR_1, VhostUserMsg *VAR_2) { char VAR_3[CMSG_SPACE(VHOST_MEMORY_MAX_NREGIONS * sizeof(int))] = { }; struct iovec VAR_4 = { .iov_base = (char *)VAR_2, .iov_len = VHOST_USER_HDR_SIZE, }; struct msghdr VAR_5 = { .msg_iov = &VAR_4, .msg_iovl...
[ "FUNC_0(VuDev *VAR_0, int VAR_1, VhostUserMsg *VAR_2)\n{", "char VAR_3[CMSG_SPACE(VHOST_MEMORY_MAX_NREGIONS * sizeof(int))] = { };", "struct iovec VAR_4 = {", ".iov_base = (char *)VAR_2,\n.iov_len = VHOST_USER_HDR_SIZE,\n};", "struct msghdr VAR_5 = {", ".msg_iov = &VAR_4,\n.msg_iovlen = 1,\n.msg_control =...
[ 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 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9, 11, 13 ], [ 15 ], [ 17, 19, 21, 23, 25 ], [ 27 ], [ 29 ], [ 31 ], [ 35 ], [ 37 ], [ 39 ], [ 43 ], [ 45 ], [ 47 ], [ 49 ], [ 53 ...
6,166
static void entropy_available(void *opaque) { RndRandom *s = RNG_RANDOM(opaque); uint8_t buffer[s->size]; ssize_t len; len = read(s->fd, buffer, s->size); g_assert(len != -1); s->receive_func(s->opaque, buffer, len); s->receive_func = NULL; qemu_set_fd_handler(s->fd, NU...
true
qemu
acbbc036619092fcd2c882222e1be168bd972b3e
static void entropy_available(void *opaque) { RndRandom *s = RNG_RANDOM(opaque); uint8_t buffer[s->size]; ssize_t len; len = read(s->fd, buffer, s->size); g_assert(len != -1); s->receive_func(s->opaque, buffer, len); s->receive_func = NULL; qemu_set_fd_handler(s->fd, NU...
{ "code": [], "line_no": [] }
static void FUNC_0(void *VAR_0) { RndRandom *s = RNG_RANDOM(VAR_0); uint8_t buffer[s->size]; ssize_t len; len = read(s->fd, buffer, s->size); g_assert(len != -1); s->receive_func(s->VAR_0, buffer, len); s->receive_func = NULL; qemu_set_fd_handler(s->fd, NULL, NULL, NULL...
[ "static void FUNC_0(void *VAR_0)\n{", "RndRandom *s = RNG_RANDOM(VAR_0);", "uint8_t buffer[s->size];", "ssize_t len;", "len = read(s->fd, buffer, s->size);", "g_assert(len != -1);", "s->receive_func(s->VAR_0, buffer, len);", "s->receive_func = NULL;", "qemu_set_fd_handler(s->fd, NULL, NULL, NULL);" ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 13 ], [ 18 ], [ 22 ], [ 24 ], [ 28 ] ]
6,167
static float32 addFloat32Sigs( float32 a, float32 b, flag zSign STATUS_PARAM) { int16 aExp, bExp, zExp; uint32_t aSig, bSig, zSig; int16 expDiff; aSig = extractFloat32Frac( a ); aExp = extractFloat32Exp( a ); bSig = extractFloat32Frac( b ); bExp = extractFloat32Exp( b ); expDi...
true
qemu
e6afc87f804abee7d0479be5e8e31c56d885fafb
static float32 addFloat32Sigs( float32 a, float32 b, flag zSign STATUS_PARAM) { int16 aExp, bExp, zExp; uint32_t aSig, bSig, zSig; int16 expDiff; aSig = extractFloat32Frac( a ); aExp = extractFloat32Exp( a ); bSig = extractFloat32Frac( b ); bExp = extractFloat32Exp( b ); expDi...
{ "code": [ " if ( STATUS(flush_to_zero) ) return packFloat32( zSign, 0, 0 );", " if ( STATUS(flush_to_zero) ) return packFloat32( zSign, 0, 0 );" ], "line_no": [ 95, 95 ] }
static float32 FUNC_0( float32 a, float32 b, flag zSign STATUS_PARAM) { int16 aExp, bExp, zExp; uint32_t aSig, bSig, zSig; int16 expDiff; aSig = extractFloat32Frac( a ); aExp = extractFloat32Exp( a ); bSig = extractFloat32Frac( b ); bExp = extractFloat32Exp( b ); expDiff = aEx...
[ "static float32 FUNC_0( float32 a, float32 b, flag zSign STATUS_PARAM)\n{", "int16 aExp, bExp, zExp;", "uint32_t aSig, bSig, zSig;", "int16 expDiff;", "aSig = extractFloat32Frac( a );", "aExp = extractFloat32Exp( a );", "bSig = extractFloat32Frac( b );", "bExp = extractFloat32Exp( b );", "expDiff = ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ...
6,168
static void rc4030_write(void *opaque, hwaddr addr, uint64_t data, unsigned int size) { rc4030State *s = opaque; uint32_t val = data; addr &= 0x3fff; trace_rc4030_write(addr, val); switch (addr & ~0x3) { /* Global config register */ case 0x0000: ...
true
qemu
c0a3172fa6bbddcc73192f2a2c48d0bf3a7ba61c
static void rc4030_write(void *opaque, hwaddr addr, uint64_t data, unsigned int size) { rc4030State *s = opaque; uint32_t val = data; addr &= 0x3fff; trace_rc4030_write(addr, val); switch (addr & ~0x3) { case 0x0000: s->config = val; b...
{ "code": [ " s->itr = val;" ], "line_no": [ 229 ] }
static void FUNC_0(void *VAR_0, hwaddr VAR_1, uint64_t VAR_2, unsigned int VAR_3) { rc4030State *s = VAR_0; uint32_t val = VAR_2; VAR_1 &= 0x3fff; trace_rc4030_write(VAR_1, val); switch (VAR_1 & ~0x3) { case 0x0000: s->config = val; br...
[ "static void FUNC_0(void *VAR_0, hwaddr VAR_1, uint64_t VAR_2,\nunsigned int VAR_3)\n{", "rc4030State *s = VAR_0;", "uint32_t val = VAR_2;", "VAR_1 &= 0x3fff;", "trace_rc4030_write(VAR_1, val);", "switch (VAR_1 & ~0x3) {", "case 0x0000:\ns->config = val;", "break;", "case 0x0018:\nrc4030_dma_tt_upda...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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 ]
[ [ 1, 3, 5 ], [ 7 ], [ 9 ], [ 11 ], [ 15 ], [ 19 ], [ 23, 25 ], [ 27 ], [ 31, 33 ], [ 35 ], [ 39, 41 ], [ 43 ], [ 47, 49 ], [ 53, 55 ], [ 57 ], [ 61, 63 ], [...
6,169
int qcow2_grow_l1_table(BlockDriverState *bs, int min_size, bool exact_size) { BDRVQcowState *s = bs->opaque; int new_l1_size, new_l1_size2, ret, i; uint64_t *new_l1_table; int64_t new_l1_table_offset; uint8_t data[12]; if (min_size <= s->l1_size) return 0; if (exact_siz...
true
qemu
2cf7cfa1cde6672b8a35bbed3fbc989f28c05dce
int qcow2_grow_l1_table(BlockDriverState *bs, int min_size, bool exact_size) { BDRVQcowState *s = bs->opaque; int new_l1_size, new_l1_size2, ret, i; uint64_t *new_l1_table; int64_t new_l1_table_offset; uint8_t data[12]; if (min_size <= s->l1_size) return 0; if (exact_siz...
{ "code": [ "int qcow2_grow_l1_table(BlockDriverState *bs, int min_size, bool exact_size)", " int new_l1_size, new_l1_size2, ret, i;", " int64_t new_l1_table_offset;", " fprintf(stderr, \"grow l1_table from %d to %d\\n\", s->l1_size, new_l1_size);" ], "line_no": [ 1, 7, 11, ...
int FUNC_0(BlockDriverState *VAR_0, int VAR_1, bool VAR_2) { BDRVQcowState *s = VAR_0->opaque; int VAR_3, VAR_4, VAR_5, VAR_6; uint64_t *new_l1_table; int64_t new_l1_table_offset; uint8_t data[12]; if (VAR_1 <= s->l1_size) return 0; if (VAR_2) { VAR_3 = VAR_1; ...
[ "int FUNC_0(BlockDriverState *VAR_0, int VAR_1, bool VAR_2)\n{", "BDRVQcowState *s = VAR_0->opaque;", "int VAR_3, VAR_4, VAR_5, VAR_6;", "uint64_t *new_l1_table;", "int64_t new_l1_table_offset;", "uint8_t data[12];", "if (VAR_1 <= s->l1_size)\nreturn 0;", "if (VAR_2) {", "VAR_3 = VAR_1;", "} else ...
[ 1, 0, 1, 0, 1, 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 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 17, 19 ], [ 23 ], [ 25 ], [ 27 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [ 49, 51 ...
6,170
static bool qemu_vmstop_requested(RunState *r) { if (vmstop_requested < RUN_STATE_MAX) { *r = vmstop_requested; vmstop_requested = RUN_STATE_MAX; return true; } return false; }
true
qemu
74892d2468b9f0c56b915ce94848d6f7fac39740
static bool qemu_vmstop_requested(RunState *r) { if (vmstop_requested < RUN_STATE_MAX) { *r = vmstop_requested; vmstop_requested = RUN_STATE_MAX; return true; } return false; }
{ "code": [ "static bool qemu_vmstop_requested(RunState *r)", " if (vmstop_requested < RUN_STATE_MAX) {", " *r = vmstop_requested;", " vmstop_requested = RUN_STATE_MAX;", " return true;", " return false;" ], "line_no": [ 1, 5, 7, 9, 11, 17...
static bool FUNC_0(RunState *r) { if (vmstop_requested < RUN_STATE_MAX) { *r = vmstop_requested; vmstop_requested = RUN_STATE_MAX; return true; } return false; }
[ "static bool FUNC_0(RunState *r)\n{", "if (vmstop_requested < RUN_STATE_MAX) {", "*r = vmstop_requested;", "vmstop_requested = RUN_STATE_MAX;", "return true;", "}", "return false;", "}" ]
[ 1, 1, 1, 1, 1, 0, 1, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 17 ], [ 19 ] ]
6,171
int kvm_irqchip_add_adapter_route(KVMState *s, AdapterInfo *adapter) { struct kvm_irq_routing_entry kroute; int virq; if (!kvm_gsi_routing_enabled()) { return -ENOSYS; } virq = kvm_irqchip_get_virq(s); if (virq < 0) { return virq; } kroute.gsi = virq; ...
true
qemu
e9af2fef242ce92f86d3d5c1a94c3199ff1e24c9
int kvm_irqchip_add_adapter_route(KVMState *s, AdapterInfo *adapter) { struct kvm_irq_routing_entry kroute; int virq; if (!kvm_gsi_routing_enabled()) { return -ENOSYS; } virq = kvm_irqchip_get_virq(s); if (virq < 0) { return virq; } kroute.gsi = virq; ...
{ "code": [ " struct kvm_irq_routing_entry kroute;" ], "line_no": [ 5 ] }
int FUNC_0(KVMState *VAR_0, AdapterInfo *VAR_1) { struct kvm_irq_routing_entry VAR_2; int VAR_3; if (!kvm_gsi_routing_enabled()) { return -ENOSYS; } VAR_3 = kvm_irqchip_get_virq(VAR_0); if (VAR_3 < 0) { return VAR_3; } VAR_2.gsi = VAR_3; VAR_2.type =...
[ "int FUNC_0(KVMState *VAR_0, AdapterInfo *VAR_1)\n{", "struct kvm_irq_routing_entry VAR_2;", "int VAR_3;", "if (!kvm_gsi_routing_enabled()) {", "return -ENOSYS;", "}", "VAR_3 = kvm_irqchip_get_virq(VAR_0);", "if (VAR_3 < 0) {", "return VAR_3;", "}", "VAR_2.gsi = VAR_3;", "VAR_2.type = KVM_IRQ_...
[ 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 ], [ 11 ], [ 13 ], [ 15 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 47 ], [ 49...
6,172
static int filter_frame(AVFilterLink *inlink, AVFilterBufferRef *buf) { AVFilterContext *ctx = inlink->dst; AlphaMergeContext *merge = ctx->priv; int is_alpha = (inlink == ctx->inputs[1]); struct FFBufQueue *queue = (is_alpha ? &merge->queue_alpha : &merge->queue_main); ff_bufqueue_...
true
FFmpeg
255be0734d9293309b42d8029d2004ec3732c8bc
static int filter_frame(AVFilterLink *inlink, AVFilterBufferRef *buf) { AVFilterContext *ctx = inlink->dst; AlphaMergeContext *merge = ctx->priv; int is_alpha = (inlink == ctx->inputs[1]); struct FFBufQueue *queue = (is_alpha ? &merge->queue_alpha : &merge->queue_main); ff_bufqueue_...
{ "code": [ " ff_filter_frame(ctx->outputs[0], avfilter_ref_buffer(main_buf, ~0));" ], "line_no": [ 43 ] }
static int FUNC_0(AVFilterLink *VAR_0, AVFilterBufferRef *VAR_1) { AVFilterContext *ctx = VAR_0->dst; AlphaMergeContext *merge = ctx->priv; int VAR_2 = (VAR_0 == ctx->inputs[1]); struct FFBufQueue *VAR_3 = (VAR_2 ? &merge->queue_alpha : &merge->queue_main); ff_bufqueue_add(ctx, VAR_...
[ "static int FUNC_0(AVFilterLink *VAR_0, AVFilterBufferRef *VAR_1)\n{", "AVFilterContext *ctx = VAR_0->dst;", "AlphaMergeContext *merge = ctx->priv;", "int VAR_2 = (VAR_0 == ctx->inputs[1]);", "struct FFBufQueue *VAR_3 =\n(VAR_2 ? &merge->queue_alpha : &merge->queue_main);", "ff_bufqueue_add(ctx, VAR_3, VA...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 11 ], [ 13, 15 ], [ 17 ], [ 21 ], [ 23 ], [ 27, 29 ], [ 33 ], [ 35 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ], [ 49 ], [ 51 ] ]
6,173
static void id3v2_read_ttag(AVFormatContext *s, int taglen, char *dst, int dstlen) { char *q; int len; if(dstlen > 0) dst[0]= 0; if(taglen < 1) return; taglen--; /* account for encoding type byte */ dstlen--; /* Leave space for zero terminator */ switch(get_by...
true
FFmpeg
03289958938e91dc9bc398fdf1489677c6030063
static void id3v2_read_ttag(AVFormatContext *s, int taglen, char *dst, int dstlen) { char *q; int len; if(dstlen > 0) dst[0]= 0; if(taglen < 1) return; taglen--; dstlen--; switch(get_byte(s->pb)) { case 0: q = dst; while(taglen--)...
{ "code": [ " len = FFMIN(taglen, dstlen);" ], "line_no": [ 51 ] }
static void FUNC_0(AVFormatContext *VAR_0, int VAR_1, char *VAR_2, int VAR_3) { char *VAR_4; int VAR_5; if(VAR_3 > 0) VAR_2[0]= 0; if(VAR_1 < 1) return; VAR_1--; VAR_3--; switch(get_byte(VAR_0->pb)) { case 0: VAR_4 = VAR_2; while(...
[ "static void FUNC_0(AVFormatContext *VAR_0, int VAR_1, char *VAR_2, int VAR_3)\n{", "char *VAR_4;", "int VAR_5;", "if(VAR_3 > 0)\nVAR_2[0]= 0;", "if(VAR_1 < 1)\nreturn;", "VAR_1--;", "VAR_3--;", "switch(get_byte(VAR_0->pb)) {", "case 0:\nVAR_4 = VAR_2;", "while(VAR_1--) {", "uint8_t tmp;", "PU...
[ 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 ], [ 11, 13 ], [ 15, 17 ], [ 21 ], [ 23 ], [ 27 ], [ 31, 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [ 49, 51 ], [ 53 ], [ 55...
6,175
static void spatial_decompose97i(DWTELEM *buffer, int width, int height, int stride){ int y; DWTELEM *b0= buffer + mirror(-4-1, height-1)*stride; DWTELEM *b1= buffer + mirror(-4 , height-1)*stride; DWTELEM *b2= buffer + mirror(-4+1, height-1)*stride; DWTELEM *b3= buffer + mirror(-4+2, height-1...
true
FFmpeg
13705b69ebe9e375fdb52469760a0fbb5f593cc1
static void spatial_decompose97i(DWTELEM *buffer, int width, int height, int stride){ int y; DWTELEM *b0= buffer + mirror(-4-1, height-1)*stride; DWTELEM *b1= buffer + mirror(-4 , height-1)*stride; DWTELEM *b2= buffer + mirror(-4+1, height-1)*stride; DWTELEM *b3= buffer + mirror(-4+2, height-1...
{ "code": [ " if(b3 <= b5) horizontal_decompose97i(b4, width);", " if(y+4 < height) horizontal_decompose97i(b5, width);", " if(b3 <= b5) vertical_decompose97iH0(b3, b4, b5, width);", " if(b2 <= b4) vertical_decompose97iL0(b2, b3, b4, width);", " if(b1 <= b3) ...
static void FUNC_0(DWTELEM *VAR_0, int VAR_1, int VAR_2, int VAR_3){ int VAR_4; DWTELEM *b0= VAR_0 + mirror(-4-1, VAR_2-1)*VAR_3; DWTELEM *b1= VAR_0 + mirror(-4 , VAR_2-1)*VAR_3; DWTELEM *b2= VAR_0 + mirror(-4+1, VAR_2-1)*VAR_3; DWTELEM *b3= VAR_0 + mirror(-4+2, VAR_2-1)*VAR_3; for(VAR_...
[ "static void FUNC_0(DWTELEM *VAR_0, int VAR_1, int VAR_2, int VAR_3){", "int VAR_4;", "DWTELEM *b0= VAR_0 + mirror(-4-1, VAR_2-1)*VAR_3;", "DWTELEM *b1= VAR_0 + mirror(-4 , VAR_2-1)*VAR_3;", "DWTELEM *b2= VAR_0 + mirror(-4+1, VAR_2-1)*VAR_3;", "DWTELEM *b3= VAR_0 + mirror(-4+2, VAR_2-1)*VAR_3;", "for(V...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1 ], [ 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 15 ], [ 17 ], [ 19 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31, 33 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [ 49 ...
6,176
static inline void RENAME(yuy2ToY)(uint8_t *dst, const uint8_t *src, int width, uint32_t *unused) { #if COMPILE_TEMPLATE_MMX __asm__ volatile( "movq "MANGLE(bm01010101)", %%mm2 \n\t" "mov %0, %%"REG_a" \n\t" "1: ...
true
FFmpeg
c3ab0004ae4dffc32494ae84dd15cfaa909a7884
static inline void RENAME(yuy2ToY)(uint8_t *dst, const uint8_t *src, int width, uint32_t *unused) { #if COMPILE_TEMPLATE_MMX __asm__ volatile( "movq "MANGLE(bm01010101)", %%mm2 \n\t" "mov %0, %%"REG_a" \n\t" "1: ...
{ "code": [ "static inline void RENAME(yuy2ToY)(uint8_t *dst, const uint8_t *src, int width, uint32_t *unused)" ], "line_no": [ 1 ] }
static inline void FUNC_0(yuy2ToY)(uint8_t *dst, const uint8_t *src, int width, uint32_t *unused) { #if COMPILE_TEMPLATE_MMX __asm__ volatile( "movq "MANGLE(bm01010101)", %%mm2 \n\t" "mov %0, %%"REG_a" \n\t" "1: ...
[ "static inline void FUNC_0(yuy2ToY)(uint8_t *dst, const uint8_t *src, int width, uint32_t *unused)\n{", "#if COMPILE_TEMPLATE_MMX\n__asm__ volatile(\n\"movq \"MANGLE(bm01010101)\", %%mm2 \\n\\t\"\n\"mov %0, %%\"REG_a\" \\n\\t\"\n\"1: \\n\\...
[ 1, 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 ] ]
6,177
static ssize_t gem_receive(VLANClientState *nc, const uint8_t *buf, size_t size) { unsigned desc[2]; target_phys_addr_t packet_desc_addr, last_desc_addr; GemState *s; unsigned rxbufsize, bytes_to_copy; unsigned rxbuf_offset; uint8_t rxbuf[2048]; uint8_t *rxbuf_ptr; ...
true
qemu
5fbe02e8bb7c62ee55b8edc5fd688c369164c49c
static ssize_t gem_receive(VLANClientState *nc, const uint8_t *buf, size_t size) { unsigned desc[2]; target_phys_addr_t packet_desc_addr, last_desc_addr; GemState *s; unsigned rxbufsize, bytes_to_copy; unsigned rxbuf_offset; uint8_t rxbuf[2048]; uint8_t *rxbuf_ptr; ...
{ "code": [ " memset(rxbuf + size, 0, sizeof(rxbuf - size));" ], "line_no": [ 125 ] }
static ssize_t FUNC_0(VLANClientState *nc, const uint8_t *buf, size_t size) { unsigned VAR_0[2]; target_phys_addr_t packet_desc_addr, last_desc_addr; GemState *s; unsigned VAR_1, VAR_2; unsigned VAR_3; uint8_t rxbuf[2048]; uint8_t *rxbuf_ptr; s = DO_UPCAST(NICState...
[ "static ssize_t FUNC_0(VLANClientState *nc, const uint8_t *buf, size_t size)\n{", "unsigned VAR_0[2];", "target_phys_addr_t packet_desc_addr, last_desc_addr;", "GemState *s;", "unsigned VAR_1, VAR_2;", "unsigned VAR_3;", "uint8_t rxbuf[2048];", "uint8_t *rxbuf_ptr;", "s = DO_UPCAST(NICSt...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 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...
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 21 ], [ 27 ], [ 29 ], [ 31 ], [ 37 ], [ 39 ], [ 41 ], [ 47 ], [ 49 ], [ 55 ], [ 59 ], [ 61 ...
6,178
static int mov_parse_stsd_data(MOVContext *c, AVIOContext *pb, AVStream *st, MOVStreamContext *sc, int size) { if (st->codec->codec_tag == MKTAG('t','m','c','d')) { st->codec->extradata_size = size; st->codec->extradata = av_mallo...
true
FFmpeg
5c720657c23afd798ae0db7c7362eb859a89ab3d
static int mov_parse_stsd_data(MOVContext *c, AVIOContext *pb, AVStream *st, MOVStreamContext *sc, int size) { if (st->codec->codec_tag == MKTAG('t','m','c','d')) { st->codec->extradata_size = size; st->codec->extradata = av_mallo...
{ "code": [ " avio_read(pb, st->codec->extradata, size);" ], "line_no": [ 19 ] }
static int FUNC_0(MOVContext *VAR_0, AVIOContext *VAR_1, AVStream *VAR_2, MOVStreamContext *VAR_3, int VAR_4) { if (VAR_2->codec->codec_tag == MKTAG('t','m','VAR_0','d')) { VAR_2->codec->extradata_size = VAR_4; VAR_2->codec->extra...
[ "static int FUNC_0(MOVContext *VAR_0, AVIOContext *VAR_1,\nAVStream *VAR_2, MOVStreamContext *VAR_3,\nint VAR_4)\n{", "if (VAR_2->codec->codec_tag == MKTAG('t','m','VAR_0','d')) {", "VAR_2->codec->extradata_size = VAR_4;", "VAR_2->codec->extradata = av_malloc(VAR_4 + FF_INPUT_BUFFER_PADDING_SIZE);", "if (!V...
[ 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5, 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15, 17 ], [ 19 ], [ 21 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ] ]
6,179
int kvm_irqchip_update_msi_route(KVMState *s, int virq, MSIMessage msg) { struct kvm_irq_routing_entry kroute; if (!kvm_irqchip_in_kernel()) { return -ENOSYS; } kroute.gsi = virq; kroute.type = KVM_IRQ_ROUTING_MSI; kroute.flags = 0; kroute.u.msi.address_lo = (uint32_t)ms...
true
qemu
0fbc20740342713f282b118b4a446c4c43df3f4a
int kvm_irqchip_update_msi_route(KVMState *s, int virq, MSIMessage msg) { struct kvm_irq_routing_entry kroute; if (!kvm_irqchip_in_kernel()) { return -ENOSYS; } kroute.gsi = virq; kroute.type = KVM_IRQ_ROUTING_MSI; kroute.flags = 0; kroute.u.msi.address_lo = (uint32_t)ms...
{ "code": [ " struct kvm_irq_routing_entry kroute;", " struct kvm_irq_routing_entry kroute;" ], "line_no": [ 5, 5 ] }
int FUNC_0(KVMState *VAR_0, int VAR_1, MSIMessage VAR_2) { struct kvm_irq_routing_entry VAR_3; if (!kvm_irqchip_in_kernel()) { return -ENOSYS; } VAR_3.gsi = VAR_1; VAR_3.type = KVM_IRQ_ROUTING_MSI; VAR_3.flags = 0; VAR_3.u.msi.address_lo = (uint32_t)VAR_2.address; V...
[ "int FUNC_0(KVMState *VAR_0, int VAR_1, MSIMessage VAR_2)\n{", "struct kvm_irq_routing_entry VAR_3;", "if (!kvm_irqchip_in_kernel()) {", "return -ENOSYS;", "}", "VAR_3.gsi = VAR_1;", "VAR_3.type = KVM_IRQ_ROUTING_MSI;", "VAR_3.flags = 0;", "VAR_3.u.msi.address_lo = (uint32_t)VAR_2.address;", "VAR_...
[ 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 9 ], [ 11 ], [ 13 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 31 ], [ 33 ] ]
6,180
static void rv34_gen_vlc(const uint8_t *bits, int size, VLC *vlc, const uint8_t *insyms, const int num) { int i; int counts[17] = {0}, codes[17]; uint16_t cw[size], syms[size]; uint8_t bits2[size]; int maxbits = 0, realsize = 0; for(i = 0; i < size; i++){ ...
false
FFmpeg
3df18b3ed1177037892ce5b3db113d52dcdcdbf3
static void rv34_gen_vlc(const uint8_t *bits, int size, VLC *vlc, const uint8_t *insyms, const int num) { int i; int counts[17] = {0}, codes[17]; uint16_t cw[size], syms[size]; uint8_t bits2[size]; int maxbits = 0, realsize = 0; for(i = 0; i < size; i++){ ...
{ "code": [], "line_no": [] }
static void FUNC_0(const uint8_t *VAR_0, int VAR_1, VLC *VAR_2, const uint8_t *VAR_3, const int VAR_4) { int VAR_5; int VAR_6[17] = {0}, VAR_7[17]; uint16_t cw[VAR_1], syms[VAR_1]; uint8_t bits2[VAR_1]; int VAR_8 = 0, VAR_9 = 0; for(VAR_5 = 0; VAR_5 < VAR_1; VA...
[ "static void FUNC_0(const uint8_t *VAR_0, int VAR_1, VLC *VAR_2, const uint8_t *VAR_3,\nconst int VAR_4)\n{", "int VAR_5;", "int VAR_6[17] = {0}, VAR_7[17];", "uint16_t cw[VAR_1], syms[VAR_1];", "uint8_t bits2[VAR_1];", "int VAR_8 = 0, VAR_9 = 0;", "for(VAR_5 = 0; VAR_5 < VAR_1; VAR_5++){", "if(VAR_0[...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [...
6,181
static int proxy_lremovexattr(FsContext *ctx, V9fsPath *fs_path, const char *name) { int retval; V9fsString xname; v9fs_string_init(&xname); v9fs_string_sprintf(&xname, "%s", name); retval = v9fs_request(ctx->private, T_LREMOVEXATTR, NULL, "ss", ...
false
qemu
494a8ebe713055d3946183f4b395f85a18b43e9e
static int proxy_lremovexattr(FsContext *ctx, V9fsPath *fs_path, const char *name) { int retval; V9fsString xname; v9fs_string_init(&xname); v9fs_string_sprintf(&xname, "%s", name); retval = v9fs_request(ctx->private, T_LREMOVEXATTR, NULL, "ss", ...
{ "code": [], "line_no": [] }
static int FUNC_0(FsContext *VAR_0, V9fsPath *VAR_1, const char *VAR_2) { int VAR_3; V9fsString xname; v9fs_string_init(&xname); v9fs_string_sprintf(&xname, "%s", VAR_2); VAR_3 = v9fs_request(VAR_0->private, T_LREMOVEXATTR, NULL, "ss", ...
[ "static int FUNC_0(FsContext *VAR_0, V9fsPath *VAR_1,\nconst char *VAR_2)\n{", "int VAR_3;", "V9fsString xname;", "v9fs_string_init(&xname);", "v9fs_string_sprintf(&xname, \"%s\", VAR_2);", "VAR_3 = v9fs_request(VAR_0->private, T_LREMOVEXATTR, NULL, \"ss\",\nVAR_1, &xname);", "v9fs_string_free(&xname);"...
[ 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 ] ]
6,182
static int get_blocksize(BlockDriverState *bdrv) { uint8_t cmd[10]; uint8_t buf[8]; uint8_t sensebuf[8]; sg_io_hdr_t io_header; int ret; memset(cmd, 0, sizeof(cmd)); memset(buf, 0, sizeof(buf)); cmd[0] = READ_CAPACITY_10; memset(&io_header, 0, sizeof(io_header)); i...
false
qemu
fe0ed71279eb442b920f0080c763438dbaa09f74
static int get_blocksize(BlockDriverState *bdrv) { uint8_t cmd[10]; uint8_t buf[8]; uint8_t sensebuf[8]; sg_io_hdr_t io_header; int ret; memset(cmd, 0, sizeof(cmd)); memset(buf, 0, sizeof(buf)); cmd[0] = READ_CAPACITY_10; memset(&io_header, 0, sizeof(io_header)); i...
{ "code": [], "line_no": [] }
static int FUNC_0(BlockDriverState *VAR_0) { uint8_t cmd[10]; uint8_t buf[8]; uint8_t sensebuf[8]; sg_io_hdr_t io_header; int VAR_1; memset(cmd, 0, sizeof(cmd)); memset(buf, 0, sizeof(buf)); cmd[0] = READ_CAPACITY_10; memset(&io_header, 0, sizeof(io_header)); io_he...
[ "static int FUNC_0(BlockDriverState *VAR_0)\n{", "uint8_t cmd[10];", "uint8_t buf[8];", "uint8_t sensebuf[8];", "sg_io_hdr_t io_header;", "int VAR_1;", "memset(cmd, 0, sizeof(cmd));", "memset(buf, 0, sizeof(buf));", "cmd[0] = READ_CAPACITY_10;", "memset(&io_header, 0, sizeof(io_header));", "io_h...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 17 ], [ 19 ], [ 21 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 47 ...
6,184
ssize_t nbd_receive_reply(int csock, struct nbd_reply *reply) { uint8_t buf[NBD_REPLY_SIZE]; uint32_t magic; if (read_sync(csock, buf, sizeof(buf)) != sizeof(buf)) { LOG("read failed"); errno = EINVAL; return -1; } /* Reply [ 0 .. 3] magic (NBD_REPL...
false
qemu
185b43386ad999c80bdc58e41b87f05e5b3e8463
ssize_t nbd_receive_reply(int csock, struct nbd_reply *reply) { uint8_t buf[NBD_REPLY_SIZE]; uint32_t magic; if (read_sync(csock, buf, sizeof(buf)) != sizeof(buf)) { LOG("read failed"); errno = EINVAL; return -1; } magic = be32_to_cpup((uint32_t*)...
{ "code": [], "line_no": [] }
ssize_t FUNC_0(int csock, struct nbd_reply *reply) { uint8_t buf[NBD_REPLY_SIZE]; uint32_t magic; if (read_sync(csock, buf, sizeof(buf)) != sizeof(buf)) { LOG("read failed"); errno = EINVAL; return -1; } magic = be32_to_cpup((uint32_t*)buf); ...
[ "ssize_t FUNC_0(int csock, struct nbd_reply *reply)\n{", "uint8_t buf[NBD_REPLY_SIZE];", "uint32_t magic;", "if (read_sync(csock, buf, sizeof(buf)) != sizeof(buf)) {", "LOG(\"read failed\");", "errno = EINVAL;", "return -1;", "}", "magic = be32_to_cpup((uint32_t*)buf);", "reply->error = be32_to_c...
[ 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 ], [ 35 ], [ 37 ], [ 39 ], [ 43, 45 ], [ 47 ], [ 51 ], [ 53 ], [ 55 ], [ 57 ], [ 59 ], [ 61 ], ...
6,187
static void usb_mouse_class_initfn(ObjectClass *klass, void *data) { USBDeviceClass *uc = USB_DEVICE_CLASS(klass); uc->init = usb_mouse_initfn; uc->product_desc = "QEMU USB Mouse"; uc->usb_desc = &desc_mouse; uc->handle_packet = usb_generic_handle_packet; uc->handle_r...
false
qemu
7f595609b49615b07c50b7182c4ef125c39cb5da
static void usb_mouse_class_initfn(ObjectClass *klass, void *data) { USBDeviceClass *uc = USB_DEVICE_CLASS(klass); uc->init = usb_mouse_initfn; uc->product_desc = "QEMU USB Mouse"; uc->usb_desc = &desc_mouse; uc->handle_packet = usb_generic_handle_packet; uc->handle_r...
{ "code": [], "line_no": [] }
static void FUNC_0(ObjectClass *VAR_0, void *VAR_1) { USBDeviceClass *uc = USB_DEVICE_CLASS(VAR_0); uc->init = usb_mouse_initfn; uc->product_desc = "QEMU USB Mouse"; uc->usb_desc = &desc_mouse; uc->handle_packet = usb_generic_handle_packet; uc->handle_reset = usb_hi...
[ "static void FUNC_0(ObjectClass *VAR_0, void *VAR_1)\n{", "USBDeviceClass *uc = USB_DEVICE_CLASS(VAR_0);", "uc->init = usb_mouse_initfn;", "uc->product_desc = \"QEMU USB Mouse\";", "uc->usb_desc = &desc_mouse;", "uc->handle_packet = usb_generic_handle_packet;", "uc->handle_reset = u...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ] ]
6,188
static void test_validate_fail_struct_nested(TestInputVisitorData *data, const void *unused) { UserDefNested *udp = NULL; Error *err = NULL; Visitor *v; v = validate_test_init(data, "{ 'string0': 'string0', 'dict1': { 'string1': 'string1', 'dict2': {...
false
qemu
b6fcf32d9b851a83dedcb609091236b97cc4a985
static void test_validate_fail_struct_nested(TestInputVisitorData *data, const void *unused) { UserDefNested *udp = NULL; Error *err = NULL; Visitor *v; v = validate_test_init(data, "{ 'string0': 'string0', 'dict1': { 'string1': 'string1', 'dict2': {...
{ "code": [], "line_no": [] }
static void FUNC_0(TestInputVisitorData *VAR_0, const void *VAR_1) { UserDefNested *udp = NULL; Error *err = NULL; Visitor *v; v = validate_test_init(VAR_0, "{ 'string0': 'string0', 'dict1': { 'string1': 'string1', 'dict2': { 'userdef1': { 'integer':...
[ "static void FUNC_0(TestInputVisitorData *VAR_0,\nconst void *VAR_1)\n{", "UserDefNested *udp = NULL;", "Error *err = NULL;", "Visitor *v;", "v = validate_test_init(VAR_0, \"{ 'string0': 'string0', 'dict1': { 'string1': 'string1', 'dict2': { 'userdef1': { 'integer': 42, 'string': 'string', 'extra': [42, 23,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5 ], [ 7 ], [ 9 ], [ 11 ], [ 15 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ] ]
6,190
static int expand_zero_clusters_in_l1(BlockDriverState *bs, uint64_t *l1_table, int l1_size, int64_t *visited_l1_entries, int64_t l1_entries, BlockDriverAmendStatusCB *status_cb) { BDRVQcowState *s...
false
qemu
a3f1afb43a09e4577571c044c48f2ba9e6e4ad06
static int expand_zero_clusters_in_l1(BlockDriverState *bs, uint64_t *l1_table, int l1_size, int64_t *visited_l1_entries, int64_t l1_entries, BlockDriverAmendStatusCB *status_cb) { BDRVQcowState *s...
{ "code": [], "line_no": [] }
static int FUNC_0(BlockDriverState *VAR_0, uint64_t *VAR_1, int VAR_2, int64_t *VAR_3, int64_t VAR_4, BlockDriverAmendStatusCB *VAR_5) { BDRVQcowState *s = VAR_0->opaque; bool is_active_l1 = (...
[ "static int FUNC_0(BlockDriverState *VAR_0, uint64_t *VAR_1,\nint VAR_2, int64_t *VAR_3,\nint64_t VAR_4,\nBlockDriverAmendStatusCB *VAR_5)\n{", "BDRVQcowState *s = VAR_0->opaque;", "bool is_active_l1 = (VAR_1 == s->VAR_1);", "uint64_t *l2_table = NULL;", "int VAR_6;", "int VAR_7, VAR_8;", "if (!is_activ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ], [ 51 ], [ 55 ], [...
6,191
static int request_frame(AVFilterLink *outlink) { AVFilterContext *ctx = outlink->src; TrimContext *s = ctx->priv; int ret; s->got_output = 0; while (!s->got_output) { if (s->eof) return AVERROR_EOF; ret = ff_request_frame(ctx->inputs[0]); if (...
false
FFmpeg
ed1c83508ec920bfef773e3aa3ac1764a65826ec
static int request_frame(AVFilterLink *outlink) { AVFilterContext *ctx = outlink->src; TrimContext *s = ctx->priv; int ret; s->got_output = 0; while (!s->got_output) { if (s->eof) return AVERROR_EOF; ret = ff_request_frame(ctx->inputs[0]); if (...
{ "code": [], "line_no": [] }
static int FUNC_0(AVFilterLink *VAR_0) { AVFilterContext *ctx = VAR_0->src; TrimContext *s = ctx->priv; int VAR_1; s->got_output = 0; while (!s->got_output) { if (s->eof) return AVERROR_EOF; VAR_1 = ff_request_frame(ctx->inputs[0]); if (VAR_1 <...
[ "static int FUNC_0(AVFilterLink *VAR_0)\n{", "AVFilterContext *ctx = VAR_0->src;", "TrimContext *s = ctx->priv;", "int VAR_1;", "s->got_output = 0;", "while (!s->got_output) {", "if (s->eof)\nreturn AVERROR_EOF;", "VAR_1 = ff_request_frame(ctx->inputs[0]);", "if (VAR_1 < 0)\nreturn VAR_1;", ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 13 ], [ 15 ], [ 17, 19 ], [ 23 ], [ 25, 27 ], [ 29 ], [ 33 ], [ 35 ] ]
6,192
int ff_ivi_decode_frame(AVCodecContext *avctx, void *data, int *got_frame, AVPacket *avpkt) { IVI45DecContext *ctx = avctx->priv_data; const uint8_t *buf = avpkt->data; AVFrame *frame = data; int buf_size = avpkt->size; int result, p, b;...
false
FFmpeg
e121ac634ba324a318f4a97f978dcfb48da6b735
int ff_ivi_decode_frame(AVCodecContext *avctx, void *data, int *got_frame, AVPacket *avpkt) { IVI45DecContext *ctx = avctx->priv_data; const uint8_t *buf = avpkt->data; AVFrame *frame = data; int buf_size = avpkt->size; int result, p, b;...
{ "code": [], "line_no": [] }
int FUNC_0(AVCodecContext *VAR_0, void *VAR_1, int *VAR_2, AVPacket *VAR_3) { IVI45DecContext *ctx = VAR_0->priv_data; const uint8_t *VAR_4 = VAR_3->VAR_1; AVFrame *frame = VAR_1; int VAR_5 = VAR_3->size; int VAR_6, VAR_7, VAR_8; ...
[ "int FUNC_0(AVCodecContext *VAR_0, void *VAR_1, int *VAR_2,\nAVPacket *VAR_3)\n{", "IVI45DecContext *ctx = VAR_0->priv_data;", "const uint8_t *VAR_4 = VAR_3->VAR_1;", "AVFrame *frame = VAR_1;", "int VAR_5 = VAR_3->size;", "int VAR_6, VAR_7, VAR_8;", "init_get_bits(&ctx->g...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ [ 1, 3, 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 19 ], [ 21 ], [ 23 ], [ 27 ], [ 29 ], [ 31, 33 ], [ 35 ], [ 37 ], [ 39, 41 ], [ 45, 47 ], [ 49 ], [ 51 ...
6,194
static void tcg_out_brcond32(TCGContext *s, TCGCond cond, TCGArg arg1, TCGArg arg2, int const_arg2, int label_index, int small) { tcg_out_cmp(s, arg1, arg2, const_arg2, 0); tcg_out_jxx(s, tcg_cond_to_jcc[cond], label_index, small); }
false
qemu
bec1631100323fac0900aea71043d5c4e22fc2fa
static void tcg_out_brcond32(TCGContext *s, TCGCond cond, TCGArg arg1, TCGArg arg2, int const_arg2, int label_index, int small) { tcg_out_cmp(s, arg1, arg2, const_arg2, 0); tcg_out_jxx(s, tcg_cond_to_jcc[cond], label_index, small); }
{ "code": [], "line_no": [] }
static void FUNC_0(TCGContext *VAR_0, TCGCond VAR_1, TCGArg VAR_2, TCGArg VAR_3, int VAR_4, int VAR_5, int VAR_6) { tcg_out_cmp(VAR_0, VAR_2, VAR_3, VAR_4, 0); tcg_out_jxx(VAR_0, tcg_cond_to_jcc[VAR_1], VAR_5, VAR_6); }
[ "static void FUNC_0(TCGContext *VAR_0, TCGCond VAR_1,\nTCGArg VAR_2, TCGArg VAR_3, int VAR_4,\nint VAR_5, int VAR_6)\n{", "tcg_out_cmp(VAR_0, VAR_2, VAR_3, VAR_4, 0);", "tcg_out_jxx(VAR_0, tcg_cond_to_jcc[VAR_1], VAR_5, VAR_6);", "}" ]
[ 0, 0, 0, 0 ]
[ [ 1, 3, 5, 7 ], [ 9 ], [ 11 ], [ 13 ] ]
6,195
void qemu_chr_free(CharDriverState *chr) { if (chr->chr_close) { chr->chr_close(chr); } g_free(chr->filename); g_free(chr->label); qemu_opts_del(chr->opts); g_free(chr); }
false
qemu
d0d7708ba29cbcc343364a46bff981e0ff88366f
void qemu_chr_free(CharDriverState *chr) { if (chr->chr_close) { chr->chr_close(chr); } g_free(chr->filename); g_free(chr->label); qemu_opts_del(chr->opts); g_free(chr); }
{ "code": [], "line_no": [] }
void FUNC_0(CharDriverState *VAR_0) { if (VAR_0->chr_close) { VAR_0->chr_close(VAR_0); } g_free(VAR_0->filename); g_free(VAR_0->label); qemu_opts_del(VAR_0->opts); g_free(VAR_0); }
[ "void FUNC_0(CharDriverState *VAR_0)\n{", "if (VAR_0->chr_close) {", "VAR_0->chr_close(VAR_0);", "}", "g_free(VAR_0->filename);", "g_free(VAR_0->label);", "qemu_opts_del(VAR_0->opts);", "g_free(VAR_0);", "}" ]
[ 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ] ]
6,200
void replay_shutdown_request(void) { if (replay_mode == REPLAY_MODE_RECORD) { replay_mutex_lock(); replay_put_event(EVENT_SHUTDOWN); replay_mutex_unlock(); } }
false
qemu
802f045a5f61b781df55e4492d896b4d20503ba7
void replay_shutdown_request(void) { if (replay_mode == REPLAY_MODE_RECORD) { replay_mutex_lock(); replay_put_event(EVENT_SHUTDOWN); replay_mutex_unlock(); } }
{ "code": [], "line_no": [] }
void FUNC_0(void) { if (replay_mode == REPLAY_MODE_RECORD) { replay_mutex_lock(); replay_put_event(EVENT_SHUTDOWN); replay_mutex_unlock(); } }
[ "void FUNC_0(void)\n{", "if (replay_mode == REPLAY_MODE_RECORD) {", "replay_mutex_lock();", "replay_put_event(EVENT_SHUTDOWN);", "replay_mutex_unlock();", "}", "}" ]
[ 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ] ]
6,201
target_phys_addr_t memory_region_section_get_iotlb(CPUArchState *env, MemoryRegionSection *section, target_ulong vaddr, target_phys_addr_t paddr, ...
false
qemu
a8170e5e97ad17ca169c64ba87ae2f53850dab4c
target_phys_addr_t memory_region_section_get_iotlb(CPUArchState *env, MemoryRegionSection *section, target_ulong vaddr, target_phys_addr_t paddr, ...
{ "code": [], "line_no": [] }
target_phys_addr_t FUNC_0(CPUArchState *env, MemoryRegionSection *section, target_ulong vaddr, target_phys_addr_t paddr, ...
[ "target_phys_addr_t FUNC_0(CPUArchState *env,\nMemoryRegionSection *section,\ntarget_ulong vaddr,\ntarget_phys_addr_t paddr,\nint prot,\ntarget_ulong *address)\n{", "target_phys_addr_t iotlb;", "CPUWatchpoint *wp;", "if (memory_region_is_ram(section->mr)) {", "iotlb = (memory_region_get_ram_addr(section->mr...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5, 7, 9, 11, 13 ], [ 15 ], [ 17 ], [ 21 ], [ 25, 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ], [ 53 ], [ 55 ], [ 57 ], [ 65 ], [ 67 ], [ 71 ...
6,203
static int vpx_decode(AVCodecContext *avctx, void *data, int *got_frame, AVPacket *avpkt) { VPxContext *ctx = avctx->priv_data; AVFrame *picture = data; const void *iter = NULL; const void *iter_alpha = NULL; struct vpx_image *img, *img_alpha; int ret; uint8_t *side_dat...
true
FFmpeg
f8593c2f492a514b67533a877b716a25d3770418
static int vpx_decode(AVCodecContext *avctx, void *data, int *got_frame, AVPacket *avpkt) { VPxContext *ctx = avctx->priv_data; AVFrame *picture = data; const void *iter = NULL; const void *iter_alpha = NULL; struct vpx_image *img, *img_alpha; int ret; uint8_t *side_dat...
{ "code": [], "line_no": [] }
static int FUNC_0(AVCodecContext *VAR_0, void *VAR_1, int *VAR_2, AVPacket *VAR_3) { VPxContext *ctx = VAR_0->priv_data; AVFrame *picture = VAR_1; const void *VAR_4 = NULL; const void *VAR_5 = NULL; struct vpx_image *VAR_6, *VAR_7; int VAR_8; uint8_t *side_data = NULL; ...
[ "static int FUNC_0(AVCodecContext *VAR_0,\nvoid *VAR_1, int *VAR_2, AVPacket *VAR_3)\n{", "VPxContext *ctx = VAR_0->priv_data;", "AVFrame *picture = VAR_1;", "const void *VAR_4 = NULL;", "const void *VAR_5 = NULL;", "struct vpx_image *VAR_6, *VAR_7;", "int VAR_8;", "uint8_t *side_data = NULL;", "int...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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 ],...
6,204
static void tcg_out_movi_int(TCGContext *s, TCGType type, TCGReg ret, tcg_target_long arg, bool in_prologue) { intptr_t tb_diff; tcg_target_long tmp; int shift; tcg_debug_assert(TCG_TARGET_REG_BITS == 64 || type == TCG_TYPE_I32); if (TCG_TARGET_REG_BITS == 64 ...
true
qemu
030ffe39dd4128eb90483af82a5b23b23054a466
static void tcg_out_movi_int(TCGContext *s, TCGType type, TCGReg ret, tcg_target_long arg, bool in_prologue) { intptr_t tb_diff; tcg_target_long tmp; int shift; tcg_debug_assert(TCG_TARGET_REG_BITS == 64 || type == TCG_TYPE_I32); if (TCG_TARGET_REG_BITS == 64 ...
{ "code": [ " tcg_out32(s, LD | TAI(ret, TCG_REG_TB, 0));" ], "line_no": [ 147 ] }
static void FUNC_0(TCGContext *VAR_0, TCGType VAR_1, TCGReg VAR_2, tcg_target_long VAR_3, bool VAR_4) { intptr_t tb_diff; tcg_target_long tmp; int VAR_5; tcg_debug_assert(TCG_TARGET_REG_BITS == 64 || VAR_1 == TCG_TYPE_I32); if (TCG_TARGET_REG_BITS == 64 && VAR...
[ "static void FUNC_0(TCGContext *VAR_0, TCGType VAR_1, TCGReg VAR_2,\ntcg_target_long VAR_3, bool VAR_4)\n{", "intptr_t tb_diff;", "tcg_target_long tmp;", "int VAR_5;", "tcg_debug_assert(TCG_TARGET_REG_BITS == 64 || VAR_1 == TCG_TYPE_I32);", "if (TCG_TARGET_REG_BITS == 64 && VAR_1 == TCG_TYPE_I32) {", "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, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ [ 1, 3, 5 ], [ 7 ], [ 9 ], [ 11 ], [ 15 ], [ 19 ], [ 21 ], [ 23 ], [ 29 ], [ 31 ], [ 33 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ], [ 55 ], [ 57 ], [ 59 ], [...
6,205
static int mpjpeg_read_probe(AVProbeData *p) { AVIOContext *pb; char line[128] = { 0 }; int ret = 0; pb = avio_alloc_context(p->buf, p->buf_size, 0, NULL, NULL, NULL, NULL); if (!pb) return AVERROR(ENOMEM); if (p->buf_size < 2 || p->buf[0] != '-' || p->buf[1] != '-') ...
true
FFmpeg
caf7be30b11288c498fae67be4741bfbf083d977
static int mpjpeg_read_probe(AVProbeData *p) { AVIOContext *pb; char line[128] = { 0 }; int ret = 0; pb = avio_alloc_context(p->buf, p->buf_size, 0, NULL, NULL, NULL, NULL); if (!pb) return AVERROR(ENOMEM); if (p->buf_size < 2 || p->buf[0] != '-' || p->buf[1] != '-') ...
{ "code": [ " return 0;" ], "line_no": [ 23 ] }
static int FUNC_0(AVProbeData *VAR_0) { AVIOContext *pb; char VAR_1[128] = { 0 }; int VAR_2 = 0; pb = avio_alloc_context(VAR_0->buf, VAR_0->buf_size, 0, NULL, NULL, NULL, NULL); if (!pb) return AVERROR(ENOMEM); if (VAR_0->buf_size < 2 || VAR_0->buf[0] != '-' || VAR_0->buf[1] ...
[ "static int FUNC_0(AVProbeData *VAR_0)\n{", "AVIOContext *pb;", "char VAR_1[128] = { 0 };", "int VAR_2 = 0;", "pb = avio_alloc_context(VAR_0->buf, VAR_0->buf_size, 0, NULL, NULL, NULL, NULL);", "if (!pb)\nreturn AVERROR(ENOMEM);", "if (VAR_0->buf_size < 2 || VAR_0->buf[0] != '-' || VAR_0->buf[1] != '-')...
[ 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 13 ], [ 15, 17 ], [ 21, 23 ], [ 27 ], [ 29 ], [ 31, 33 ], [ 37 ], [ 39 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ], [ 51 ], [ 55 ], [...
6,208
static int flic_read_header(AVFormatContext *s) { FlicDemuxContext *flic = s->priv_data; AVIOContext *pb = s->pb; unsigned char header[FLIC_HEADER_SIZE]; AVStream *st, *ast; int speed; int magic_number; unsigned char preamble[FLIC_PREAMBLE_SIZE]; flic->frame_number = 0; ...
true
FFmpeg
00e1bf8a587e26029f8fb20a35c65b99fe14196b
static int flic_read_header(AVFormatContext *s) { FlicDemuxContext *flic = s->priv_data; AVIOContext *pb = s->pb; unsigned char header[FLIC_HEADER_SIZE]; AVStream *st, *ast; int speed; int magic_number; unsigned char preamble[FLIC_PREAMBLE_SIZE]; flic->frame_number = 0; ...
{ "code": [ " st->codec->extradata_size = FLIC_HEADER_SIZE;", " st->codec->extradata_size = 12;" ], "line_no": [ 85, 187 ] }
static int FUNC_0(AVFormatContext *VAR_0) { FlicDemuxContext *flic = VAR_0->priv_data; AVIOContext *pb = VAR_0->pb; unsigned char VAR_1[FLIC_HEADER_SIZE]; AVStream *st, *ast; int VAR_2; int VAR_3; unsigned char VAR_4[FLIC_PREAMBLE_SIZE]; flic->frame_number = 0; if...
[ "static int FUNC_0(AVFormatContext *VAR_0)\n{", "FlicDemuxContext *flic = VAR_0->priv_data;", "AVIOContext *pb = VAR_0->pb;", "unsigned char VAR_1[FLIC_HEADER_SIZE];", "AVStream *st, *ast;", "int VAR_2;", "int VAR_3;", "unsigned char VAR_4[FLIC_PREAMBLE_SIZE];", "flic->frame_number = 0;", "if (avi...
[ 0, 0, 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, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 21 ], [ 27, 29 ], [ 33 ], [ 35 ], [ 37, 39 ], [ 45 ], [ 47, 49 ], [ 51 ], [ 53 ], [ 55 ], [...
6,209
ds1225y_t *ds1225y_init(target_phys_addr_t mem_base, const char *filename) { ds1225y_t *s; int mem_index1, mem_index2; s = qemu_mallocz(sizeof(ds1225y_t)); if (!s) return NULL; s->mem_base = mem_base; s->capacity = 0x2000; /* Fixed for ds1225y chip: 8K */ s->file...
true
qemu
30aa5c0d303c334c646e9db1ebadda0c0db8b13f
ds1225y_t *ds1225y_init(target_phys_addr_t mem_base, const char *filename) { ds1225y_t *s; int mem_index1, mem_index2; s = qemu_mallocz(sizeof(ds1225y_t)); if (!s) return NULL; s->mem_base = mem_base; s->capacity = 0x2000; s->filename = filename; ...
{ "code": [ "ds1225y_t *ds1225y_init(target_phys_addr_t mem_base, const char *filename)\r", " ds1225y_t *s;\r", " int mem_index1, mem_index2;\r", " s = qemu_mallocz(sizeof(ds1225y_t));\r", " if (!s)\r", " return NULL;\r", " s->mem_base = mem_base;\r", " s->file...
ds1225y_t *FUNC_0(target_phys_addr_t mem_base, const char *filename) { ds1225y_t *s; int VAR_0, VAR_1; s = qemu_mallocz(sizeof(ds1225y_t)); if (!s) return NULL; s->mem_base = mem_base; s->capacity = 0x2000; s->filename = filename; VAR_0 = cpu_reg...
[ "ds1225y_t *FUNC_0(target_phys_addr_t mem_base, const char *filename)\n{", "ds1225y_t *s;", "int VAR_0, VAR_1;", "s = qemu_mallocz(sizeof(ds1225y_t));", "if (!s)\nreturn NULL;", "s->mem_base = mem_base;", "s->capacity = 0x2000;", "s->filename = filename;", "VAR_0 = cpu_register_io_memory(0, nvram_re...
[ 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0 ]
[ [ 1, 3 ], [ 5 ], [ 7 ], [ 11 ], [ 13, 15 ], [ 17 ], [ 19 ], [ 21 ], [ 27 ], [ 29 ], [ 33 ], [ 35 ], [ 37 ], [ 39 ] ]
6,210
static void sdp_parse_line(AVFormatContext *s, SDPParseState *s1, int letter, const char *buf) { RTSPState *rt = s->priv_data; char buf1[64], st_type[64]; const char *p; enum AVMediaType codec_type; int payload_type; AVStream *st; RTSPStream *rtsp_st; ...
true
FFmpeg
604c9b1196c70d79bbbc1f23e75f6a8253a74da3
static void sdp_parse_line(AVFormatContext *s, SDPParseState *s1, int letter, const char *buf) { RTSPState *rt = s->priv_data; char buf1[64], st_type[64]; const char *p; enum AVMediaType codec_type; int payload_type; AVStream *st; RTSPStream *rtsp_st; ...
{ "code": [ " if (!rt->ts && CONFIG_RTPDEC)" ], "line_no": [ 213 ] }
static void FUNC_0(AVFormatContext *VAR_0, SDPParseState *VAR_1, int VAR_2, const char *VAR_3) { RTSPState *rt = VAR_0->priv_data; char VAR_4[64], VAR_5[64]; const char *VAR_6; enum AVMediaType VAR_7; int VAR_8; AVStream *st; RTSPStream *rtsp_st; RTSP...
[ "static void FUNC_0(AVFormatContext *VAR_0, SDPParseState *VAR_1,\nint VAR_2, const char *VAR_3)\n{", "RTSPState *rt = VAR_0->priv_data;", "char VAR_4[64], VAR_5[64];", "const char *VAR_6;", "enum AVMediaType VAR_7;", "int VAR_8;", "AVStream *st;", "RTSPStream *rtsp_st;", "RTSPSource *rtsp_src;", ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ [ 1, 3, 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 29 ], [ 33 ], [ 35, 37 ], [ 39 ], [ 41, 43 ], [ 45, 47 ], [ 49 ...
6,211
av_cold void ff_mlpdsp_init(MLPDSPContext *c) { c->mlp_filter_channel = mlp_filter_channel; if (ARCH_X86) ff_mlpdsp_init_x86(c); }
true
FFmpeg
15a29c39d9ef15b0783c04b3228e1c55f6701ee3
av_cold void ff_mlpdsp_init(MLPDSPContext *c) { c->mlp_filter_channel = mlp_filter_channel; if (ARCH_X86) ff_mlpdsp_init_x86(c); }
{ "code": [], "line_no": [] }
av_cold void FUNC_0(MLPDSPContext *c) { c->mlp_filter_channel = mlp_filter_channel; if (ARCH_X86) ff_mlpdsp_init_x86(c); }
[ "av_cold void FUNC_0(MLPDSPContext *c)\n{", "c->mlp_filter_channel = mlp_filter_channel;", "if (ARCH_X86)\nff_mlpdsp_init_x86(c);", "}" ]
[ 0, 0, 0, 0 ]
[ [ 1, 3 ], [ 5 ], [ 9, 11 ], [ 13 ] ]
6,212
int coroutine_fn qemu_co_sendv(int sockfd, struct iovec *iov, int len, int iov_offset) { int total = 0; int ret; while (len) { ret = qemu_sendv(sockfd, iov, len, iov_offset + total); if (ret < 0) { if (errno == EAGAIN) { qem...
true
qemu
3e80bf9351f8fec9085c46df6da075efd5e71003
int coroutine_fn qemu_co_sendv(int sockfd, struct iovec *iov, int len, int iov_offset) { int total = 0; int ret; while (len) { ret = qemu_sendv(sockfd, iov, len, iov_offset + total); if (ret < 0) { if (errno == EAGAIN) { qem...
{ "code": [ " ret = qemu_sendv(sockfd, iov, len, iov_offset + total);" ], "line_no": [ 13 ] }
int VAR_0 qemu_co_sendv(int sockfd, struct iovec *iov, int len, int iov_offset) { int total = 0; int ret; while (len) { ret = qemu_sendv(sockfd, iov, len, iov_offset + total); if (ret < 0) { if (errno == EAGAIN) { qemu_corou...
[ "int VAR_0 qemu_co_sendv(int sockfd, struct iovec *iov,\nint len, int iov_offset)\n{", "int total = 0;", "int ret;", "while (len) {", "ret = qemu_sendv(sockfd, iov, len, iov_offset + total);", "if (ret < 0) {", "if (errno == EAGAIN) {", "qemu_coroutine_yield();", "continue;", "}", "if (total == ...
[ 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ [ 1, 3, 5 ], [ 7 ], [ 9 ], [ 11 ], [ 13 ], [ 15 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 41 ], [ 43 ] ]
6,213
static PullupField *make_field_queue(PullupContext *s, int len) { PullupField *head, *f; f = head = av_mallocz(sizeof(*head)); if (!f) return NULL; if (alloc_metrics(s, f) < 0) { av_free(f); return NULL; } for (; len > 0; len--) { f->next = av_mal...
true
FFmpeg
5b0ce5d4e3660fb0fc86779cbd027b47b1758c9f
static PullupField *make_field_queue(PullupContext *s, int len) { PullupField *head, *f; f = head = av_mallocz(sizeof(*head)); if (!f) return NULL; if (alloc_metrics(s, f) < 0) { av_free(f); return NULL; } for (; len > 0; len--) { f->next = av_mal...
{ "code": [ " f = f->next;", " free_field_queue(head, &f);", " free_field_queue(head, &f);" ], "line_no": [ 43, 33, 33 ] }
static PullupField *FUNC_0(PullupContext *s, int len) { PullupField *head, *f; f = head = av_mallocz(sizeof(*head)); if (!f) return NULL; if (alloc_metrics(s, f) < 0) { av_free(f); return NULL; } for (; len > 0; len--) { f->next = av_mallocz(sizeo...
[ "static PullupField *FUNC_0(PullupContext *s, int len)\n{", "PullupField *head, *f;", "f = head = av_mallocz(sizeof(*head));", "if (!f)\nreturn NULL;", "if (alloc_metrics(s, f) < 0) {", "av_free(f);", "return NULL;", "}", "for (; len > 0; len--) {", "f->next = av_mallocz(sizeof(*f->next));", "if...
[ 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 ]
[ [ 1, 3 ], [ 5 ], [ 9 ], [ 11, 13 ], [ 17 ], [ 19 ], [ 21 ], [ 23 ], [ 27 ], [ 29 ], [ 31 ], [ 33 ], [ 35 ], [ 37 ], [ 41 ], [ 43 ], [ 45 ], [ 47 ], [ 49 ], ...
6,214
static void lan9118_writel(void *opaque, target_phys_addr_t offset, uint32_t val) { lan9118_state *s = (lan9118_state *)opaque; offset &= 0xff; //DPRINTF("Write reg 0x%02x = 0x%08x\n", (int)offset, val); if (offset >= 0x20 && offset < 0x40) { /* TX FIFO */...
true
qemu
c46a3ea025b147d58e4c7a222307ccba1e9e376f
static void lan9118_writel(void *opaque, target_phys_addr_t offset, uint32_t val) { lan9118_state *s = (lan9118_state *)opaque; offset &= 0xff; if (offset >= 0x20 && offset < 0x40) { tx_fifo_push(s, val); return; } switch (off...
{ "code": [ " lan9118_eeprom_cmd(s, (val >> 28) & 7, val & 0xff);" ], "line_no": [ 241 ] }
static void FUNC_0(void *VAR_0, target_phys_addr_t VAR_1, uint32_t VAR_2) { lan9118_state *s = (lan9118_state *)VAR_0; VAR_1 &= 0xff; if (VAR_1 >= 0x20 && VAR_1 < 0x40) { tx_fifo_push(s, VAR_2); return; } switch (VAR_1) { ...
[ "static void FUNC_0(void *VAR_0, target_phys_addr_t VAR_1,\nuint32_t VAR_2)\n{", "lan9118_state *s = (lan9118_state *)VAR_0;", "VAR_1 &= 0xff;", "if (VAR_1 >= 0x20 && VAR_1 < 0x40) {", "tx_fifo_push(s, VAR_2);", "return;", "}", "switch (VAR_1) {", "case CSR_IRQ_CFG:\ns->irq_cfg = (s->irq_cfg & IRQ_I...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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 ], [ 19 ], [ 21 ], [ 23 ], [ 25 ], [ 27, 31 ], [ 33 ], [ 35, 37 ], [ 39 ], [ 41, 43 ], [ 45 ], [ 47 ], [ 49, 51 ], [ 53 ], [...