Hello,
I'm porting posgresql for QNX RTP. Compiling is ok, but
"/usr/local/pqsql/bin/initdb -D data" command say:
FATAL: s_lock(0x081e6029) at spin.c:162, stuck spinlock. Aborting.
FATAL: s_lock(0x081e6029) at spin.c:162, stuck spinlock. Aborting.
sed: couldn't write 86 items to {standard output}: Broken pipe
Abort (core dumped)
initdb failed.
Data directory dat will not be removed at user's reques
I review sem_'s family functions and use de QNX sem function, except
S_LOCK_FREE:
It is in src/include/storing/s_lock.h
#define S_LOCK_FREE(lock) s_lock_free_x86(lock)
#define TAS(lock) (sem_trywait((lock)) < 0)
#define S_UNLOCK(lock) sem_post((lock))
#define S_INIT_LOCK(lock) sem_init((lock), 1, 1)
It is in src/backend/port/x86/sem.c and make for my
int
s_lock_free_x86(sem_t *lock) {
int value;
sem_getvalue(lock, &value);
return value;
};
The testing program "s_lock_test" (is inside in s_lock.c) working properly.
Any idea. Sorry for my english.
Thanks,
Leandro Medina
(Ingdesi Group - R&D)