search for: bitshift

Displaying 20 results from an estimated 26 matches for "bitshift".

2018 Dec 03
3
[PATCH nbdkit v3] common: Move shared bitmap code to a common library.
v2: https://www.redhat.com/archives/libguestfs/2018-December/msg00039.html v2 -> v3: - Fix all the issues raised in Eric's review. - Precompute some numbers to make the calculations easier. - Calculations now use bitshifts and masks in preference to division and modulo. - Clear existing bits before setting (which fixes a bug in the cache filter). Rich.
2004 Sep 10
2
flac can occasionally be worse than shorten
...cases > where shorten out > performs it? > But, hey I program too and this seems like a pain > in the arse to code > just for these limited cases actually, it's pretty easy to code and not even a real speed penalty, but I would have to find a place in the stream header for the bitshift #, which is pretty tight right now. if I can I will probably add it. Josh __________________________________________________ Do You Yahoo!? Yahoo! Auctions - Buy the things you want at great prices! http://auctions.yahoo.com/
2018 Dec 03
0
[PATCH nbdkit v3] common: Move shared bitmap code to a common library.
...P_H + +#include <stdint.h> +#include <assert.h> + +#include "ispowerof2.h" + +/* This is the bitmap structure. */ +struct bitmap { + unsigned blksize; /* Block size. */ + unsigned bpb; /* Bits per block (1, 2, 4, 8 only). */ + /* bpb = 1 << bitshift ibpb = 8/bpb + 1 0 8 + 2 1 4 + 4 2 2 + 8 3 1 + */ + unsigned bitshift, ibpb; + + uint8_t *bitmap; /* The bitmap. */ + size_t size; /* Size of bitmap in bytes. */ +}; + +static...
2004 Sep 10
2
flac can occasionally be worse than shorten
...signal for each block, subtracts it out and stores it separately. but this is pretty useless for the predictors that shorten uses as they are pretty insensitive to the mean (try different values of -m from 0 to whatever and note practically no difference in file size). 2. it tests for exploitable bitshift within a block; e.g. if all the samples in a block have 0 for the least significant two bits, it stores the bitshift (2) and shifts the signal down 2 bits. normally this is also useless for CD audio since even the LSB is not stationary and there is no exploitable bit shift. BUT, you have stumbled...
2017 Jun 21
2
[PATCH 01/11] drm/fb-helper: do a generic fb_setcmap helper in terms of crtc .gamma_set
...;fb; >> - >> - if (info->fix.visual == FB_VISUAL_TRUECOLOR) { > > This case here seems gone, and it was also the pièce de résistance when I > tried tackling fbdev lut support. As far as I understand this stuff we do > not support FB_VISUAL_TRUECOLOR palette, and all that bitshifting here is > pointless. But I'm honestly not really clear. > > I think removing this case should also be a separate patch, and I'd very > much prefer that someone with some fbdev-clue would ack it. No need for anyone with fbdev-clue, just run fbset -i. :) fbcon uses a TRUECOLO...
2019 Jun 11
2
Support 64-bit pointers in open source RV32 GPU ISA using register pairs and address space ID’s
> > Hi Reshabh, and congratulations on being selected for GSoC. I haven't > looked at supporting larger than native-width pointers on a target > before. I'd thought that AVR might be relevant (given it uses 16-bit > pointers but has 8-bit GPRs). See the description here > <http://lists.llvm.org/pipermail/llvm-dev/2019-January/129089.html>. > Many thanks Alex,
2019 Jan 01
0
[PATCH nbdkit v2 1/4] common/bitmap: Add bitmap_next function and tests.
...;ibpb-1)) != 0; ++blk) { + if (bitmap_get_blk (bm, blk, 0) != 0) + return blk; + } + if (blk == limit) + return -1; + + /* Now we're at a byte boundary we can use a fast string function to + * find the next non-zero byte. + */ + p = &bm->bitmap[blk >> (3 - bm->bitshift)]; + p = (const uint8_t *) next_non_zero ((const char *) p, + &bm->bitmap[bm->size] - p); + if (p == NULL) + return -1; + + /* Now check the non-zero byte to find out which bit (ie. block) is set. */ + blk = (p - bm->bitmap) << (3 - bm...
2017 Jun 20
2
[PATCH 01/11] drm/fb-helper: do a generic fb_setcmap helper in terms of crtc .gamma_set
This makes the redundant fb helpers .load_lut, .gamma_set and .gamma_get totally obsolete. I think the gamma_store can end up invalid on error. But the way I read it, that can happen in drm_mode_gamma_set_ioctl as well, so why should this pesky legacy fbdev stuff be any better? drm_fb_helper_save_lut_atomic justs saves the gamma lut for later. However, it saves it to the gamma_store which should
2017 Jun 21
0
[PATCH 01/11] drm/fb-helper: do a generic fb_setcmap helper in terms of crtc .gamma_set
...> - if (info->fix.visual == FB_VISUAL_TRUECOLOR) { > > > > This case here seems gone, and it was also the pièce de résistance when I > > tried tackling fbdev lut support. As far as I understand this stuff we do > > not support FB_VISUAL_TRUECOLOR palette, and all that bitshifting here is > > pointless. But I'm honestly not really clear. > > > > I think removing this case should also be a separate patch, and I'd very > > much prefer that someone with some fbdev-clue would ack it. > > No need for anyone with fbdev-clue, just run fbse...
2006 Dec 15
2
About "Convert 8->16 bits"
Hi everybody, I have been using speex-1.2beta1 and my input data is 8-bit unsigned so I know that I should convert from 8 to 16 bits. I've done the convertion as following. for(int i=0; i<160; ++i) { input_frame[i] = (short)( (data[2*i] << 8) | data[2*i+1]); } When my codec application didn't work right, I think that the reason is an error at this
2023 Feb 27
3
[Bug 3544] New: Support CIDR notation for host pattern matching
...ng and, in this case, leads to multiple host matchers (since one can't effectively glob a /22, for instance, without splitting it into 4x /24's) when one could suffice. Using CIDR prefixes has the additional benefit of potentially faster match processing, since comparison could be done via bitshifting/bitwise operations et. al. [0] https://api.github.com/meta (Refer to the "git" key.) -- You are receiving this mail because: You are watching the assignee of the bug.
2017 Sep 25
0
LLVM Weekly - #195, Sep 25th 2017
...of a lambda binds more closely to the delete, so this error suggests adding parentheses, instead of the generic one currently used ('expected expression')." [D36357](https://reviews.llvm.org/D36357), patch by Nicolas Lesser. * "Clarify Clang warnings about undefined behaviour for bitshifts. It happens that the current output mislead users and makes them think that Clang is wrong." [D30295](https://reviews.llvm.org/D30295), patch by Daniel Marjamäki. * "This is regarding addition of a new priority selector/heuristic for Scheduler DAG based scheduling. It adds a heuristic t...
2017 Jun 21
0
[PATCH 01/11] drm/fb-helper: do a generic fb_setcmap helper in terms of crtc .gamma_set
...mebuffer *fb = fb_helper->fb; > - > - if (info->fix.visual == FB_VISUAL_TRUECOLOR) { This case here seems gone, and it was also the pièce de résistance when I tried tackling fbdev lut support. As far as I understand this stuff we do not support FB_VISUAL_TRUECOLOR palette, and all that bitshifting here is pointless. But I'm honestly not really clear. I think removing this case should also be a separate patch, and I'd very much prefer that someone with some fbdev-clue would ack it. > - u32 *palette; > - u32 value; > - /* place color in psuedopalette */ > - if (reg...
2008 Jul 23
0
[LLVMdev] Extending vector operations
...i1> instead. For example, in conjunction > with the above-mentioned vector select, this would allow a max to be > expressed simply as a sequence of compare and select. True enough. It also leads naturally to generalized masked vector operations, which are _extremely_ handy. > Vector bitshifts would actually help with the amount of code generated > for something like a vectorized max, but makes the patterns for > recognizing these a lot longer. Right. > I realize this is probably the most controversial change amongst > these. I gather there is some concern about representi...
2004 Aug 06
7
question on downsampling
Hi, Maybe a bit off topic for this list, bt anyway. I have received several feature requests for DarkIce to support downsampling of the audio input before passing it to lame or ogg vorbis. For example the audio read from the soundcard would be 44.1kHz, and lame would get it at 22.05kHz. I figure two ways of doing this: 1. For lame, one can specify the input and the desired mp3 sampling rate,
2011 Dec 18
10
[Bug 1964] New: QoS/DSCP names false translated to ToS hex value
...----|---------|---------|---------|--------|---------><--------|---------> DSCP ECN The OpenSSH client currently translates DSCP classes directly into their hex code and fills the entire ToS field with that. Instead, it should bitshift the DSCP number by 2 bits to the left and OR it with the ECN number. E.g. class cs1 ("throughput", 0x08) becomes "000010|00". When written directly into the ToS field, that yields a DSCP of 0x02, which is undefined. The 0x08 should only be written into the highest 6 bits, and...
2017 Jun 21
2
[PATCH 01/11] drm/fb-helper: do a generic fb_setcmap helper in terms of crtc .gamma_set
...;fb; >> - >> - if (info->fix.visual == FB_VISUAL_TRUECOLOR) { > > This case here seems gone, and it was also the pièce de résistance when I > tried tackling fbdev lut support. As far as I understand this stuff we do > not support FB_VISUAL_TRUECOLOR palette, and all that bitshifting here is > pointless. But I'm honestly not really clear. Oops, sorry, I simply missed that, I'll have a closer look... > I think removing this case should also be a separate patch, and I'd very > much prefer that someone with some fbdev-clue would ack it. > >> -...
2008 Jun 26
2
[LLVMdev] Vector instructions
.... vector shl, lshr, ashr Again, these simply seem to be simply missing (compared to the other bitwise ops). Not having vector versions of shift right, and not having vector trunc, makes things like converting bitmasks of various sizes very difficult. Modern SIMD architectures have good support for bitshifts of vector types. There are of course two ways to interpret a shift on a vector type: within elements and across elements. To us, shifts within elements (i.e. the equivalent of N scalar shifts) are more important than shifts (or rotates!) across elements, but the latter could be useful in some sit...
2008 Jul 21
10
[LLVMdev] Extending vector operations
...believe it would be cleaner, simpler, and potentially more efficient, to have a vector compare that returns <N x i1> instead. For example, in conjunction with the above-mentioned vector select, this would allow a max to be expressed simply as a sequence of compare and select. Vector bitshifts would actually help with the amount of code generated for something like a vectorized max, but makes the patterns for recognizing these a lot longer. I realize this is probably the most controversial change amongst these. I gather there is some concern about representing "variable wi...
2009 Aug 17
8
drm bo accessors etc. v2
Revised patch set v2. [PATCH 1/8] drm/nouveau: bo read/write wrappers for nv04_crtc.c [PATCH 2/8] drm/nouveau: use bo accessors for push buffers [PATCH 3/8] drm/nouveau: OUT_RINGp - optimize OUT_RING loops [PATCH 4/8] drm/nv50: proper notifier_bo access in nv50_display_vblank_crtc_handler() [PATCH 5/8] drm/nouveau: access fbcon notifier via bo accessors [PATCH 6/8] drm/nouveau: screen_base and