Skip to content
Snippets Groups Projects
Select Git revision
  • benchmark-tools
  • postgres-lambda
  • master default
  • REL9_4_25
  • REL9_5_20
  • REL9_6_16
  • REL_10_11
  • REL_11_6
  • REL_12_1
  • REL_12_0
  • REL_12_RC1
  • REL_12_BETA4
  • REL9_4_24
  • REL9_5_19
  • REL9_6_15
  • REL_10_10
  • REL_11_5
  • REL_12_BETA3
  • REL9_4_23
  • REL9_5_18
  • REL9_6_14
  • REL_10_9
  • REL_11_4
23 results

tidbitmap.c

  • Tom Lane's avatar
    08e1eedf
    Fix performance problem when building a lossy tidbitmap. · 08e1eedf
    Tom Lane authored
    As pointed out by Sergey Koposov, repeated invocations of tbm_lossify can
    make building a large tidbitmap into an O(N^2) operation.  To fix, make
    sure we remove more than the minimum amount of information per call, and
    add a fallback path to behave sanely if we're unable to fit the bitmap
    within the requested amount of memory.
    
    This has been wrong since the tidbitmap code was written, so back-patch
    to all supported branches.
    08e1eedf
    History
    Fix performance problem when building a lossy tidbitmap.
    Tom Lane authored
    As pointed out by Sergey Koposov, repeated invocations of tbm_lossify can
    make building a large tidbitmap into an O(N^2) operation.  To fix, make
    sure we remove more than the minimum amount of information per call, and
    add a fallback path to behave sanely if we're unable to fit the bitmap
    within the requested amount of memory.
    
    This has been wrong since the tidbitmap code was written, so back-patch
    to all supported branches.