Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit58e539e

Browse files
committed
Long awaited port for NetBSD/m68k was finally done by Mr. Mutsuki
Nakajima. Since he is not subscribing the mailing list, I'm postinghis patches by his request. According to him, he has successfullycompiled and passed the regression test on Mac SE/30 runningNetBSD/m68k. Also, another person has reported that with the patchesPostgreSQL is working on NetBSD/sun3 too.--Tatsuo Ishii
1 parent2be1ecc commit58e539e

File tree

2 files changed

+30
-4
lines changed

2 files changed

+30
-4
lines changed

‎src/backend/storage/buffer/s_lock.c

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/storage/buffer/Attic/s_lock.c,v 1.14 1998/12/18 17:25:39 momjian Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/storage/buffer/Attic/s_lock.c,v 1.15 1998/12/26 18:15:53 momjian Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -99,6 +99,25 @@ s_lock(volatile slock_t *lock, const char *file, const int line)
9999
*/
100100

101101

102+
#if defined(__m68k__)
103+
staticvoid
104+
tas_dummy()/* really means: extern int tas(slock_t **lock); */
105+
{
106+
__asm__("\n\
107+
.global_tas\n\
108+
_tas:\n\
109+
movel sp@(0x4),a0\n\
110+
tas a0@\n\
111+
beq _success\n\
112+
moveq #-128,d0\n\
113+
rts\n\
114+
_success:\n\
115+
moveq #0,d0\n\
116+
rts\n\
117+
");
118+
}
119+
120+
#endif/* __m68k__ */
102121

103122
#if defined(PPC)
104123
/* Note: need a nice gcc constrained asm version so it can be inlined */

‎src/include/utils/memutils.h

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
*
1616
* Copyright (c) 1994, Regents of the University of California
1717
*
18-
* $Id: memutils.h,v 1.18 1998/09/07 05:35:48 momjian Exp $
18+
* $Id: memutils.h,v 1.19 1998/12/26 18:15:53 momjian Exp $
1919
*
2020
* NOTES
2121
* some of the information in this file will be moved to
@@ -58,13 +58,17 @@ tending
5858
#defineSHORTALIGN(LEN)\
5959
(((long)(LEN) + (sizeof (short) - 1)) & ~(sizeof (short) - 1))
6060

61+
#if defined(m68k)
62+
#defineINTALIGN(LEN) SHORTALIGN(LEN)
63+
#else
6164
#defineINTALIGN(LEN)\
6265
(((long)(LEN) + (sizeof (int) - 1)) & ~(sizeof (int) -1))
66+
#endif
6367

6468
/*
6569
*LONGALIGN(LEN)- length (or address) aligned for longs
6670
*/
67-
#if defined(sun)&& ! defined(sparc)
71+
#if(defined(sun)&& ! defined(sparc))|| defined(m68k)
6872
#defineLONGALIGN(LEN)SHORTALIGN(LEN)
6973
#elif defined (__alpha)
7074

@@ -81,7 +85,10 @@ tending
8185
(((long)(LEN) + (sizeof (long) - 1)) & ~(sizeof (long) -1))
8286
#endif
8387

84-
#if ! defined(sco)
88+
#if defined(m68k)
89+
#defineDOUBLEALIGN(LEN) SHORTALIGN(LEN)
90+
#defineMAXALIGN(LEN) SHORTALIGN(LEN)
91+
#elif ! defined(sco)
8592
#defineDOUBLEALIGN(LEN)\
8693
(((long)(LEN) + (sizeof (double) - 1)) & ~(sizeof (double) -1))
8794

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp