Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Greenplum
Gpdb
提交
5f0bf6cb
G
Gpdb
项目概览
Greenplum
/
Gpdb
通知
7
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
G
Gpdb
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
5f0bf6cb
编写于
11月 16, 2007
作者:
B
Bruce Momjian
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Run pgindent on remaining files now that LOOPBYTE is a usable macro.
上级
0c2c061e
变更
6
隐藏空白更改
内联
并排
Showing
6 changed file
with
44 addition
and
44 deletion
+44
-44
contrib/hstore/hstore_gist.c
contrib/hstore/hstore_gist.c
+11
-11
contrib/intarray/_intbig_gist.c
contrib/intarray/_intbig_gist.c
+1
-1
contrib/ltree/_ltree_gist.c
contrib/ltree/_ltree_gist.c
+1
-1
contrib/ltree/ltree_gist.c
contrib/ltree/ltree_gist.c
+6
-6
contrib/pg_trgm/trgm_gist.c
contrib/pg_trgm/trgm_gist.c
+9
-9
src/backend/utils/adt/tsgistidx.c
src/backend/utils/adt/tsgistidx.c
+16
-16
未找到文件。
contrib/hstore/hstore_gist.c
浏览文件 @
5f0bf6cb
...
...
@@ -146,8 +146,8 @@ ghstore_compress(PG_FUNCTION_ARGS)
LOOPBYTE
{
if
((
sign
[
i
]
&
0xff
)
!=
0xff
)
PG_RETURN_POINTER
(
retval
);
if
((
sign
[
i
]
&
0xff
)
!=
0xff
)
PG_RETURN_POINTER
(
retval
);
}
res
=
(
GISTTYPE
*
)
palloc
(
CALCGTSIZE
(
ALLISTRUE
));
...
...
@@ -169,7 +169,7 @@ ghstore_decompress(PG_FUNCTION_ARGS)
{
GISTENTRY
*
entry
=
(
GISTENTRY
*
)
PG_GETARG_POINTER
(
0
);
GISTENTRY
*
retval
;
HStore
*
key
;
HStore
*
key
;
key
=
(
HStore
*
)
PG_DETOAST_DATUM
(
entry
->
key
);
...
...
@@ -273,7 +273,7 @@ unionkey(BITVECP sbase, GISTTYPE * add)
if
(
ISALLTRUE
(
add
))
return
1
;
LOOPBYTE
sbase
[
i
]
|=
sadd
[
i
];
sbase
[
i
]
|=
sadd
[
i
];
return
0
;
}
...
...
@@ -328,7 +328,7 @@ typedef struct
{
OffsetNumber
pos
;
int4
cost
;
}
SPLITCOST
;
}
SPLITCOST
;
static
int
comparecost
(
const
void
*
a
,
const
void
*
b
)
...
...
@@ -470,7 +470,7 @@ ghstore_picksplit(PG_FUNCTION_ARGS)
{
ptr
=
GETSIGN
(
_j
);
LOOPBYTE
union_l
[
i
]
|=
ptr
[
i
];
union_l
[
i
]
|=
ptr
[
i
];
}
*
left
++
=
j
;
v
->
spl_nleft
++
;
...
...
@@ -486,7 +486,7 @@ ghstore_picksplit(PG_FUNCTION_ARGS)
{
ptr
=
GETSIGN
(
_j
);
LOOPBYTE
union_r
[
i
]
|=
ptr
[
i
];
union_r
[
i
]
|=
ptr
[
i
];
}
*
right
++
=
j
;
v
->
spl_nright
++
;
...
...
@@ -516,7 +516,7 @@ ghstore_consistent(PG_FUNCTION_ARGS)
sign
=
GETSIGN
(
entry
);
if
(
strategy
==
HStoreContainsStrategyNumber
||
strategy
==
13
/* hack for old strats */
)
if
(
strategy
==
HStoreContainsStrategyNumber
||
strategy
==
13
/* hack for old strats */
)
{
HStore
*
query
=
PG_GETARG_HS
(
1
);
HEntry
*
qe
=
ARRPTR
(
query
);
...
...
@@ -540,10 +540,10 @@ ghstore_consistent(PG_FUNCTION_ARGS)
qe
++
;
}
}
else
if
(
strategy
==
HStoreExistsStrategyNumber
)
else
if
(
strategy
==
HStoreExistsStrategyNumber
)
{
text
*
query
=
PG_GETARG_TEXT_P
(
1
);
int
crc
=
crc32_sz
(
VARDATA
(
query
),
VARSIZE
(
query
)
-
VARHDRSZ
);
text
*
query
=
PG_GETARG_TEXT_P
(
1
);
int
crc
=
crc32_sz
(
VARDATA
(
query
),
VARSIZE
(
query
)
-
VARHDRSZ
);
res
=
(
GETBIT
(
sign
,
HASHVAL
(
crc
)))
?
true
:
false
;
}
...
...
contrib/intarray/_intbig_gist.c
浏览文件 @
5f0bf6cb
...
...
@@ -319,7 +319,7 @@ typedef struct
{
OffsetNumber
pos
;
int4
cost
;
}
SPLITCOST
;
}
SPLITCOST
;
static
int
comparecost
(
const
void
*
a
,
const
void
*
b
)
...
...
contrib/ltree/_ltree_gist.c
浏览文件 @
5f0bf6cb
...
...
@@ -272,7 +272,7 @@ typedef struct
{
OffsetNumber
pos
;
int4
cost
;
}
SPLITCOST
;
}
SPLITCOST
;
static
int
comparecost
(
const
void
*
a
,
const
void
*
b
)
...
...
contrib/ltree/ltree_gist.c
浏览文件 @
5f0bf6cb
/*
* GiST support for ltree
* Teodor Sigaev <teodor@stack.net>
* $PostgreSQL: pgsql/contrib/ltree/ltree_gist.c,v 1.2
1 2007/11/16 00:13:02
momjian Exp $
* $PostgreSQL: pgsql/contrib/ltree/ltree_gist.c,v 1.2
2 2007/11/16 01:12:24
momjian Exp $
*/
#include "ltree.h"
...
...
@@ -136,8 +136,8 @@ ltree_same(PG_FUNCTION_ARGS)
{
LOOPBYTE
{
if
(
sa
[
i
]
!=
sb
[
i
])
{
if
(
sa
[
i
]
!=
sb
[
i
])
{
*
result
=
false
;
break
;
}
...
...
@@ -202,7 +202,7 @@ ltree_union(PG_FUNCTION_ARGS)
BITVECP
sc
=
LTG_SIGN
(
cur
);
LOOPBYTE
((
unsigned
char
*
)
base
)[
i
]
|=
sc
[
i
];
((
unsigned
char
*
)
base
)[
i
]
|=
sc
[
i
];
}
curtree
=
LTG_LNODE
(
cur
);
...
...
@@ -347,7 +347,7 @@ ltree_picksplit(PG_FUNCTION_ARGS)
BITVECP
sc
=
LTG_SIGN
(
lu
);
LOOPBYTE
((
unsigned
char
*
)
ls
)[
i
]
|=
sc
[
i
];
((
unsigned
char
*
)
ls
)[
i
]
|=
sc
[
i
];
}
}
}
...
...
@@ -368,7 +368,7 @@ ltree_picksplit(PG_FUNCTION_ARGS)
BITVECP
sc
=
LTG_SIGN
(
lu
);
LOOPBYTE
((
unsigned
char
*
)
rs
)[
i
]
|=
sc
[
i
];
((
unsigned
char
*
)
rs
)[
i
]
|=
sc
[
i
];
}
}
}
...
...
contrib/pg_trgm/trgm_gist.c
浏览文件 @
5f0bf6cb
...
...
@@ -115,8 +115,8 @@ gtrgm_compress(PG_FUNCTION_ARGS)
LOOPBYTE
{
if
((
sign
[
i
]
&
0xff
)
!=
0xff
)
PG_RETURN_POINTER
(
retval
);
if
((
sign
[
i
]
&
0xff
)
!=
0xff
)
PG_RETURN_POINTER
(
retval
);
}
len
=
CALCGTSIZE
(
SIGNKEY
|
ALLISTRUE
,
0
);
...
...
@@ -137,7 +137,7 @@ gtrgm_decompress(PG_FUNCTION_ARGS)
{
GISTENTRY
*
entry
=
(
GISTENTRY
*
)
PG_GETARG_POINTER
(
0
);
GISTENTRY
*
retval
;
text
*
key
;
text
*
key
;
key
=
DatumGetTextP
(
entry
->
key
);
...
...
@@ -212,7 +212,7 @@ unionkey(BITVECP sbase, TRGM * add)
return
1
;
LOOPBYTE
sbase
[
i
]
|=
sadd
[
i
];
sbase
[
i
]
|=
sadd
[
i
];
}
else
{
...
...
@@ -327,7 +327,7 @@ sizebitvec(BITVECP sign)
i
;
LOOPBYTE
size
+=
number_of_ones
[(
unsigned
char
)
sign
[
i
]];
size
+=
number_of_ones
[(
unsigned
char
)
sign
[
i
]];
return
size
;
}
...
...
@@ -394,10 +394,10 @@ typedef struct
{
bool
allistrue
;
BITVEC
sign
;
}
CACHESIGN
;
}
CACHESIGN
;
static
void
fillcache
(
CACHESIGN
*
item
,
TRGM
*
key
)
fillcache
(
CACHESIGN
*
item
,
TRGM
*
key
)
{
item
->
allistrue
=
false
;
if
(
ISARRKEY
(
key
))
...
...
@@ -413,7 +413,7 @@ typedef struct
{
OffsetNumber
pos
;
int4
cost
;
}
SPLITCOST
;
}
SPLITCOST
;
static
int
comparecost
(
const
void
*
a
,
const
void
*
b
)
...
...
@@ -426,7 +426,7 @@ comparecost(const void *a, const void *b)
static
int
hemdistcache
(
CACHESIGN
*
a
,
CACHESIGN
*
b
)
hemdistcache
(
CACHESIGN
*
a
,
CACHESIGN
*
b
)
{
if
(
a
->
allistrue
)
{
...
...
src/backend/utils/adt/tsgistidx.c
浏览文件 @
5f0bf6cb
...
...
@@ -7,7 +7,7 @@
*
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/utils/adt/tsgistidx.c,v 1.
5 2007/11/16 00:13:02
momjian Exp $
* $PostgreSQL: pgsql/src/backend/utils/adt/tsgistidx.c,v 1.
6 2007/11/16 01:12:24
momjian Exp $
*
*-------------------------------------------------------------------------
*/
...
...
@@ -50,7 +50,7 @@ typedef char *BITVECP;
typedef
struct
{
int32
vl_len_
;
/* varlena header (do not touch directly!) */
int32
vl_len_
;
/* varlena header (do not touch directly!) */
int4
flag
;
char
data
[
1
];
}
SignTSVector
;
...
...
@@ -133,8 +133,8 @@ gtsvectorout(PG_FUNCTION_ARGS)
static
int
compareint
(
const
void
*
va
,
const
void
*
vb
)
{
int4
a
=
*
((
int4
*
)
va
);
int4
b
=
*
((
int4
*
)
vb
);
int4
a
=
*
((
int4
*
)
va
);
int4
b
=
*
((
int4
*
)
vb
);
if
(
a
==
b
)
return
0
;
...
...
@@ -167,7 +167,7 @@ uniqueint(int4 *a, int4 l)
}
static
void
makesign
(
BITVECP
sign
,
SignTSVector
*
a
)
makesign
(
BITVECP
sign
,
SignTSVector
*
a
)
{
int4
k
,
len
=
ARRNELEM
(
a
);
...
...
@@ -252,8 +252,8 @@ gtsvector_compress(PG_FUNCTION_ARGS)
LOOPBYTE
{
if
((
sign
[
i
]
&
0xff
)
!=
0xff
)
PG_RETURN_POINTER
(
retval
);
if
((
sign
[
i
]
&
0xff
)
!=
0xff
)
PG_RETURN_POINTER
(
retval
);
}
len
=
CALCGTSIZE
(
SIGNKEY
|
ALLISTRUE
,
0
);
...
...
@@ -299,7 +299,7 @@ typedef struct
* is there value 'val' in array or not ?
*/
static
bool
checkcondition_arr
(
void
*
checkval
,
QueryOperand
*
val
)
checkcondition_arr
(
void
*
checkval
,
QueryOperand
*
val
)
{
int4
*
StopLow
=
((
CHKVAL
*
)
checkval
)
->
arrb
;
int4
*
StopHigh
=
((
CHKVAL
*
)
checkval
)
->
arre
;
...
...
@@ -322,7 +322,7 @@ checkcondition_arr(void *checkval, QueryOperand * val)
}
static
bool
checkcondition_bit
(
void
*
checkval
,
QueryOperand
*
val
)
checkcondition_bit
(
void
*
checkval
,
QueryOperand
*
val
)
{
return
GETBIT
(
checkval
,
HASHVAL
(
val
->
valcrc
));
}
...
...
@@ -364,7 +364,7 @@ gtsvector_consistent(PG_FUNCTION_ARGS)
}
static
int4
unionkey
(
BITVECP
sbase
,
SignTSVector
*
add
)
unionkey
(
BITVECP
sbase
,
SignTSVector
*
add
)
{
int4
i
;
...
...
@@ -487,7 +487,7 @@ sizebitvec(BITVECP sign)
i
;
LOOPBYTE
size
+=
number_of_ones
[(
unsigned
char
)
sign
[
i
]];
size
+=
number_of_ones
[(
unsigned
char
)
sign
[
i
]];
return
size
;
}
...
...
@@ -507,7 +507,7 @@ hemdistsign(BITVECP a, BITVECP b)
}
static
int
hemdist
(
SignTSVector
*
a
,
SignTSVector
*
b
)
hemdist
(
SignTSVector
*
a
,
SignTSVector
*
b
)
{
if
(
ISALLTRUE
(
a
))
{
...
...
@@ -557,7 +557,7 @@ typedef struct
}
CACHESIGN
;
static
void
fillcache
(
CACHESIGN
*
item
,
SignTSVector
*
key
)
fillcache
(
CACHESIGN
*
item
,
SignTSVector
*
key
)
{
item
->
allistrue
=
false
;
if
(
ISARRKEY
(
key
))
...
...
@@ -578,8 +578,8 @@ typedef struct
static
int
comparecost
(
const
void
*
va
,
const
void
*
vb
)
{
SPLITCOST
*
a
=
(
SPLITCOST
*
)
va
;
SPLITCOST
*
b
=
(
SPLITCOST
*
)
vb
;
SPLITCOST
*
a
=
(
SPLITCOST
*
)
va
;
SPLITCOST
*
b
=
(
SPLITCOST
*
)
vb
;
if
(
a
->
cost
==
b
->
cost
)
return
0
;
...
...
@@ -589,7 +589,7 @@ comparecost(const void *va, const void *vb)
static
int
hemdistcache
(
CACHESIGN
*
a
,
CACHESIGN
*
b
)
hemdistcache
(
CACHESIGN
*
a
,
CACHESIGN
*
b
)
{
if
(
a
->
allistrue
)
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录