Skip to content

Commit

Permalink
Replace occurrences of J9ZTPF guard macro with OMRZTPF in OMR Repository
Browse files Browse the repository at this point in the history
  • Loading branch information
jjohnst-us committed Jan 8, 2024
1 parent 714d51c commit 798380b
Show file tree
Hide file tree
Showing 10 changed files with 28 additions and 28 deletions.
2 changes: 1 addition & 1 deletion compiler/optimizer/Inliner.cpp
Expand Up @@ -18,7 +18,7 @@
*
* SPDX-License-Identifier: EPL-2.0 OR Apache-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0 OR GPL-2.0-only WITH OpenJDK-assembly-exception-1.0
*******************************************************************************/
#ifdef J9ZTPF
#ifdef OMRZTPF
#define __TPF_DO_NOT_MAP_ATOE_REMOVE
#endif

Expand Down
4 changes: 2 additions & 2 deletions include_core/omrgcconsts.h
Expand Up @@ -567,9 +567,9 @@ typedef enum {
#define METRONOME_DEFAULT_TIME_WINDOW_MICRO 60000
#endif /* OMR_GC_REALTIME */

#if defined(J9ZTPF)
#if defined(OMRZTPF)
#define ZTPF_MEMORY_RESERVE_RATIO .8
#endif /* defined(J9ZTPF) */
#endif /* defined(OMRZTPF) */

/**
* Bit geometry within header flags byte.
Expand Down
2 changes: 1 addition & 1 deletion omrmakefiles/rules.ztpf.mk
Expand Up @@ -42,7 +42,7 @@ endif
### Global Flags
###

GLOBAL_CPPFLAGS += -DLINUX -D_REENTRANT -DJ9ZTPF -DOMRZTPF -DOMRPORT_JSIG_SUPPORT -DIBMLOCKS
GLOBAL_CPPFLAGS += -DLINUX -D_REENTRANT -DOMRZTPF -DOMRPORT_JSIG_SUPPORT -DIBMLOCKS
GLOBAL_CPPFLAGS += -D_GNU_SOURCE -DIBM_ATOE -D_TPF_SOURCE -D_TPF_THREADS -DZTPF_POSIX_SOCKET

ifeq (s390,$(OMR_HOST_ARCH))
Expand Down
4 changes: 2 additions & 2 deletions port/unix/omrshsem_deprecated.c
Expand Up @@ -1060,14 +1060,14 @@ omrshsem_openSemaphore(struct OMRPortLibrary *portLibrary, intptr_t fd, char *ba
goto failDontUnlink;
}
} else {
#if defined(__GNUC__) || defined(AIXPPC) || defined(J9ZTPF)
#if defined(__GNUC__) || defined(AIXPPC) || defined(OMRZTPF)
#if defined(OSX)
/*Use _key for OSX*/
if (buf.sem_perm._key != controlinfo->ftok_key)
#elif defined(AIXPPC)
/*Use .key for AIXPPC*/
if (buf.sem_perm.key != controlinfo->ftok_key)
#elif defined(J9ZTPF)
#elif defined(OMRZTPF)
/*Use .key for z/TPF */
if (buf.key != controlinfo->ftok_key)
#elif defined(__GNUC__)
Expand Down
32 changes: 16 additions & 16 deletions port/unix/omrsysinfo.c
Expand Up @@ -83,10 +83,10 @@
#include "omrsimap.h"
#endif /* defined(J9ZOS390) */

#if defined(LINUXPPC) || (defined(S390) && defined(LINUX) && !defined(J9ZTPF)) || (defined(AARCH64) && defined(LINUX))
#if defined(LINUXPPC) || (defined(S390) && defined(LINUX) && !defined(OMRZTPF)) || (defined(AARCH64) && defined(LINUX))
#include "auxv.h"
#include <strings.h>
#endif /* defined(LINUXPPC) || (defined(S390) && defined(LINUX) && !defined(J9ZTPF)) || (defined(AARCH64) && defined(LINUX)) */
#endif /* defined(LINUXPPC) || (defined(S390) && defined(LINUX) && !defined(OMRZTPF)) || (defined(AARCH64) && defined(LINUX)) */

#if (defined(S390))
#include "omrportpriv.h"
Expand Down Expand Up @@ -258,11 +258,11 @@ static intptr_t omrsysinfo_get_aix_ppc_description(struct OMRPortLibrary *portLi
#endif /* !defined(__power_tm) */
#endif /* !defined(J9OS_I5_V7R2) && !defined(J9OS_I5_V6R1) */

#if (defined(S390) || defined(J9ZOS390) || defined(J9ZTPF))
#if (defined(S390) || defined(J9ZOS390) || defined(OMRZTPF))
static BOOLEAN omrsysinfo_test_stfle(struct OMRPortLibrary *portLibrary, uint64_t stfleBit);
static intptr_t omrsysinfo_get_s390_description(struct OMRPortLibrary *portLibrary, OMRProcessorDesc *desc);
const char * omrsysinfo_get_s390_processor_feature_name(uint32_t feature);
#endif /* defined(S390) || defined(J9ZOS390) || defined(J9ZTPF) */
#endif /* defined(S390) || defined(J9ZOS390) || defined(OMRZTPF) */

#if defined(RISCV)
static intptr_t omrsysinfo_get_riscv_description(struct OMRPortLibrary *portLibrary, OMRProcessorDesc *desc);
Expand Down Expand Up @@ -839,9 +839,9 @@ omrsysinfo_get_processor_feature_name(struct OMRPortLibrary *portLibrary, uint32
Trc_PRT_sysinfo_get_processor_feature_name_Entered(feature);
#if defined(J9X86) || defined(J9HAMMER)
rc = omrsysinfo_get_x86_processor_feature_name(feature);
#elif defined(S390) || defined(J9ZOS390) || defined(J9ZTPF) /* defined(J9X86) || defined(J9HAMMER) */
#elif defined(S390) || defined(J9ZOS390) || defined(OMRZTPF) /* defined(J9X86) || defined(J9HAMMER) */
rc = omrsysinfo_get_s390_processor_feature_name(feature);
#elif defined(AIXPPC) || defined(LINUXPPC) /* defined(S390) || defined(J9ZOS390) || defined(J9ZTPF) */
#elif defined(AIXPPC) || defined(LINUXPPC) /* defined(S390) || defined(J9ZOS390) || defined(OMRZTPF) */
rc = omrsysinfo_get_ppc_processor_feature_name(feature);
#elif defined(AARCH64) /* defined(AIXPPC) || defined(LINUXPPC) */
rc = omrsysinfo_get_aarch64_processor_feature_name(feature);
Expand Down Expand Up @@ -1408,7 +1408,7 @@ omrsysinfo_get_s390_description(struct OMRPortLibrary *portLibrary, OMRProcessor
if (OMR_ARE_NO_BITS_SET(*(int*) 200, S390_STFLE_BIT)) {
return -1;
}
#elif defined(J9ZTPF) /* defined(J9ZOS390) */
#elif defined(OMRZTPF) /* defined(J9ZOS390) */
/*
* z/TPF requires OS support for some of the Hardware Capabilities.
* Setting the auxvFeatures capabilities flag directly to mimic the query_auxv call in Linux.
Expand All @@ -1417,7 +1417,7 @@ omrsysinfo_get_s390_description(struct OMRPortLibrary *portLibrary, OMRProcessor
OMR_HWCAP_S390_STFLE|OMR_HWCAP_S390_MSA|OMR_HWCAP_S390_DFP|
OMR_HWCAP_S390_LDISP|OMR_HWCAP_S390_EIMM|OMR_HWCAP_S390_ETF3EH;

#elif defined(LINUX) /* defined(J9ZTPF) */
#elif defined(LINUX) /* defined(OMRZTPF) */
/* Some s390 features require OS support on Linux, querying auxv for AT_HWCAP bit-mask of processor capabilities. */
unsigned long auxvFeatures = query_auxv(AT_HWCAP);
#endif /* defined(LINUX) */
Expand Down Expand Up @@ -1610,9 +1610,9 @@ omrsysinfo_get_s390_description(struct OMRPortLibrary *portLibrary, OMRProcessor
if (omrsysinfo_get_s390_zos_supports_runtime_instrumentation_facility())
#endif /* defined(J9ZOS390) */
{
#if !defined(J9ZTPF)
#if !defined(OMRZTPF)
omrsysinfo_set_feature(desc, OMR_FEATURE_S390_RI);
#endif /* !defined(J9ZTPF) */
#endif /* !defined(OMRZTPF) */
}
}

Expand Down Expand Up @@ -1723,9 +1723,9 @@ omrsysinfo_get_s390_description(struct OMRPortLibrary *portLibrary, OMRProcessor
if (omrsysinfo_test_stfle(portLibrary, OMR_FEATURE_S390_VECTOR_FACILITY_ENHANCEMENT_2)) {
#if defined(J9ZOS390)
if (omrsysinfo_get_s390_zos_supports_vector_extension_facility())
#elif defined(LINUX) && !defined(J9ZTPF) /* defined(J9ZOS390) */
#elif defined(LINUX) && !defined(OMRZTPF) /* defined(J9ZOS390) */
if (OMR_ARE_ALL_BITS_SET(auxvFeatures, OMR_HWCAP_S390_VXRS))
#endif /* defined(LINUX) && !defined(J9ZTPF) */
#endif /* defined(LINUX) && !defined(OMRZTPF) */
{
omrsysinfo_set_feature(desc, OMR_FEATURE_S390_VECTOR_FACILITY_ENHANCEMENT_2);

Expand All @@ -1736,9 +1736,9 @@ omrsysinfo_get_s390_description(struct OMRPortLibrary *portLibrary, OMRProcessor
if (omrsysinfo_test_stfle(portLibrary, OMR_FEATURE_S390_VECTOR_PACKED_DECIMAL_ENHANCEMENT_FACILITY)) {
#if defined(J9ZOS390)
if (omrsysinfo_get_s390_zos_supports_vector_extension_facility())
#elif defined(LINUX) && !defined(J9ZTPF) /* defined(J9ZOS390) */
#elif defined(LINUX) && !defined(OMRZTPF) /* defined(J9ZOS390) */
if (OMR_ARE_ALL_BITS_SET(auxvFeatures, OMR_HWCAP_S390_VXRS))
#endif /* defined(LINUX) && !defined(J9ZTPF) */
#endif /* defined(LINUX) && !defined(OMRZTPF) */
{
omrsysinfo_set_feature(desc, OMR_FEATURE_S390_VECTOR_PACKED_DECIMAL_ENHANCEMENT_FACILITY);

Expand All @@ -1751,9 +1751,9 @@ omrsysinfo_get_s390_description(struct OMRPortLibrary *portLibrary, OMRProcessor
if (omrsysinfo_test_stfle(portLibrary, OMR_FEATURE_S390_VECTOR_PACKED_DECIMAL_ENHANCEMENT_FACILITY_2)) {
#if defined(J9ZOS390)
if (omrsysinfo_get_s390_zos_supports_vector_extension_facility())
#elif defined(LINUX) && !defined(J9ZTPF) /* defined(J9ZOS390) */
#elif defined(LINUX) && !defined(OMRZTPF) /* defined(J9ZOS390) */
if (OMR_ARE_ALL_BITS_SET(auxvFeatures, OMR_HWCAP_S390_VXRS))
#endif /* defined(LINUX) && !defined(J9ZTPF) */
#endif /* defined(LINUX) && !defined(OMRZTPF) */
{
omrsysinfo_set_feature(desc, OMR_FEATURE_S390_VECTOR_PACKED_DECIMAL_ENHANCEMENT_FACILITY_2);

Expand Down
4 changes: 2 additions & 2 deletions port/ztpf/omrintrospect.c
Expand Up @@ -885,7 +885,7 @@ resume_all_preempted(struct PlatformWalkData *data)


int __attribute__((optimize(0)))
J9ZTPF_getcontext( void *region )
OMRZTPF_getcontext( void *region )
{
register char *rgn asm("r2") = (char *)region;
/*
Expand Down Expand Up @@ -997,7 +997,7 @@ setup_native_thread(J9ThreadWalkState *state, thread_context *sigContext, int he
memcpy(state->current_thread->context, ((OMRUnixSignalInfo*)sigContext)->platformSignalInfo.context, size);
} else if (state->current_thread->thread_id == omrthread_get_ras_tid()) {
/* return context for current thread */
J9ZTPF_getcontext((ucontext_t*)state->current_thread->context);
OMRZTPF_getcontext((ucontext_t*)state->current_thread->context);
} else {
memcpy(state->current_thread->context, (void*)data->thread->context, size);
}
Expand Down
2 changes: 1 addition & 1 deletion port/ztpf/omrosdump.c
Expand Up @@ -310,7 +310,7 @@ omrdump_startup(struct OMRPortLibrary *portLibrary)
* The #define following is that constant in EBCDIC.
*/
#define OMRZTPF_BYTE_INTERP "\xC4\xF9\xE5\xD4"
/* J9ZTPF_BYTE_INTERP "D9VM" */
/* OMRZTPF_BYTE_INTERP "D9VM" */
/*
* z/TPF handles JVM-associated processes a little differently than all
* others. We need to mark the process block to inform the kernel that
Expand Down
2 changes: 1 addition & 1 deletion port/ztpf/omrosdump_helpers.c
Expand Up @@ -330,7 +330,7 @@ splitPathName(char *finalname, char *pathname)
* \param[in] arg->portLibrary Pointer to an initialized OMRPortLibrary
* block. If there isn't one at call time,
* leave this value NULL and set flag
* J9ZTPF_NO_PORT_LIBRARY
* OMRZTPF_NO_PORT_LIBRARY
* \param[in] arg->dibPtr Address of the DIB attached to the faulting
* UOW at post-interrupt time.
*
Expand Down
2 changes: 1 addition & 1 deletion thread/linux/omrthreadnuma.c
Expand Up @@ -43,7 +43,7 @@
#include "omrcfg.h"
#include "threaddef.h"

#if defined(J9ZTPF)
#if defined(OMRZTPF)
#define CPU_SETSIZE 4
#define CPU_ISSET(x,y) 0
#define CPU_SET(x,y) {}
Expand Down
2 changes: 1 addition & 1 deletion tools/tracegen/Port.cpp
Expand Up @@ -680,7 +680,7 @@ Port::omrfile_stat(const char *path, unsigned int flags, struct J9FileStat *buf)
buf->ownerUid = statbuf.st_uid;
buf->ownerGid = statbuf.st_gid;

#if (defined(LINUX) && !defined(J9ZTPF)) || defined(OSX)
#if (defined(LINUX) && !defined(OMRZTPF)) || defined(OSX)
if (statfs(path, &statfsbuf)) {
return RC_FAILED;
}
Expand Down

0 comments on commit 798380b

Please sign in to comment.