COMPILATION LISTING OF SEGMENT bjm_write Compiled by: Multics PL/I Compiler, Release 28e, of February 14, 1985 Compiled at: Honeywell Multics Op. - System M Compiled on: 04/04/85 0941.9 mst Thu Options: optimize map 1 2 /* *********************************************************** 3* * * 4* * Copyright, (C) Honeywell Information Systems Inc., 1983 * 5* * * 6* *********************************************************** */ 7 8 /* DESCRIPTION: 9* 10* The bjm_write procedure has entrypoints for each type of before 11* journal write operation. ANY CHANGES TO BJM_FIND_TXNS_AFTER_CRASH OR 12* BJ_TXTE_UTIL SHOULD BE EXAMINED TO BE SURE THEY AGREE WITH THE 13* MEHCANISMS IN THIS MODULE USED TO WRITE TO BEFORE JOURNALS. Likewise, 14* any changes to this module may need to be reflected in the above two 15* modules. 16* 17*LIST OF ENTRYPOINTS: 18* 19* aborted_mark (tid, tix, code) 20* before_image (fm_uid, fm_oid, ci_no, ci_parts_ptr, time_stamp, code) 21* begin_mark (tid, tix, bj_oid, code) 22* committed_mark (tid, tix, code) 23* rolled_back_mark (tid, tix, checkpoint_no, code) 24* fm_rollback_handler 25* (fm_uid, fm_oid, buff_ptr, buff_byte_len, n_ci_held, time_stamp, code) 26* fm_postcommit_handler 27* (fm_uid, fm_oid, buff_ptr, buff_byte_len, code) 28* 29*LIST OF PARAMETERS: 30* 31* tid INPUT bit (36) aligned current transaction ID 32* tix INPUT fixed bin current transaction index 33* bj_oid INPUT bit (36) aligned opening ID of a before journal or "0"b 34* checkpoint_no INPUT fixed bin (35) number of the checkpoint of previous rollback 35* fm_uid INPUT bit (36) aligned unique ID of protected file being imaged 36* fm_oid INPUT bit (36) aligned opening ID of protected file being imaged 37* ci_no INPUT fixed bin (24) unsigned control interval number in file being imaged 38* ci_parts_ptr INPUT pointer pointer to ci_parts description structure 39* buff_ptr INPUT pointer pointer to handler info buffer 40* buff_len INPUT fixed bin (17) length of fm handler image in bytes 41* n_ci_held INPUT fixed bin (27) number of control intervals held 42* time_stamp OUTPUT fixed bin (71) time at which image saved 43* code OUTPUT fixed bin (35) system status code 44* 45* This code was originally contained in five separate programs. 46**/ 47 48 /* HISTORY: 49*Written by M. Pandolf, 03/08/83. 50*Modified: 51*03/28/83 by M. Pandolf: to align record buffers. 52*04/08/83 by M. Pandolf: to use new validation protocol. 53*04/20/83 by M. Pandolf: to have abort and commit leave TID alone and 54* to zero the ok_to_write flag. 55*04/29/83 by M. Pandolf: added meters. 56*04/30/83 by L. A. Newcomb: fixed VALIDATE_TRANSACTION to goto the local error 57* exit instead of the non-local one to preserve the status code. 58*12/06/83 by L. A. Newcomb: Renamed before_journal_manager_static_ to 59* bjm_data_ and moved some cells from dm_data_ to bjm_data_. 60*06/07/84 by Lee Baldwin: Fixed to call dm_error_$no_current_transaction 61* instead of $bj_no_txn, renamed dm_error_$bj_txt_version_bad to 62* $bj_bad_txt_version. 63*10/29/84 by Matthew Pierret: Changed fm_rollback_mark to fm_rollback_handler. 64* Changed WRITE_COMMITTED_MARK to have no effect on the number of 65* transactions in the journal if writing a BEGIN_COMMIT mark instead 66* of a COMMIT mark. The latter case continues to decrease the 67* number of transactions by one. In the BEGIN_COMMIT case, the 68* number of transactions is decremented later in 69* bj_txte_util$complex_commit, when it finally writes the 70* COMMIT mark. 71* Changed to set bj_fm_handler_rec.prev_fm_handler_rec_id to 72* ZERO in the WRITE_FM_ROLLBACK_HANDLER, to 73* bj_txte.last_fm_postcommit_handler_rec_id in 74* WRITE_FM_POSTCOMMIT_HANDLER. 75* Changed to make WRITE_FM_POSTCOMMIT_HANDLER and 76* WRITE_FM_ROLLBACK_HANDLER increase the number of transactions 77* in the journal by 1 if writing the first record for a transaction. 78*03/04/85 by Lee A. Newcomb: Fixed to not write more than one BEGIN_COMMIT 79* mark. 80*03/19/85 by Steve Herbst: Fixed to initialize bjm_data_$bj_code. 81**/ 82 83 /* format: style4,indattr,ifthenstmt,ifthen,^indcomtxt,idind33 */ 84 85 /* 86* ************************************************************************ 87* ********** BEGIN bjm_write$begin_mark ********** 88* ************************************************************************ 89**/ 90 bjm_write$begin_mark: 91 procedure (p_tid, p_tix, p_bj_oid, p_begin_code); 92 93 /* copy parameters and identify self */ 94 95 txn_id = p_tid; 96 txn_index = p_tix; 97 98 p_begin_code = 0; 99 100 my_name = BEGIN_ID; 101 return_code_ptr = addr (p_begin_code); 102 103 /* before entering BJM environment, obtain a BJ OID */ 104 105 if p_bj_oid ^= ZERO 106 then bj_oid = p_bj_oid; 107 else do; 108 call before_journal_manager_$get_default_bj (bj_oid, p_begin_code); 109 if p_begin_code ^= 0 110 then goto bjm_return; 111 end; 112 113 /* invoke entry protocol common to all before_journal_manager_ */ 114 115 on cleanup call EMERGENCY_CLEANUP (); 116 117 call ENTER_BJM (); 118 119 /* fill in the transaction table entry */ 120 121 call INITIALIZE_TRANSACTION (); 122 123 /* meter */ 124 125 bjm_data_$bj_pst_ptr -> bj_pst.meters.n_calls_begin_txn = 126 bjm_data_$bj_pst_ptr -> bj_pst.meters.n_calls_begin_txn + 1; 127 bj_ppte_ptr -> bj_ppte.bj_pste_ptr -> bj_pste.meters.n_txn_started = 128 bj_ppte_ptr -> bj_ppte.bj_pste_ptr -> bj_pste.meters.n_txn_started + 1; 129 130 /* go to common wrap up point */ 131 132 goto bjm_wrap_up; 133 134 /* 135* ************************************************************************ 136* ********** BEGIN bjm_write$aborted_mark ********** 137* ************************************************************************ 138**/ 139 bjm_write$aborted_mark: 140 entry (p_tid, p_tix, p_abort_code); 141 142 /* copy parameters and identify self */ 143 144 txn_id = p_tid; 145 txn_index = p_tix; 146 147 p_abort_code = 0; 148 149 my_name = ABORT_ID; 150 return_code_ptr = addr (p_abort_code); 151 152 /* invoke entry protocol common to all before_journal_manager_ */ 153 154 on cleanup call EMERGENCY_CLEANUP (); 155 156 call ENTER_BJM (); 157 158 /* meter */ 159 160 bjm_data_$bj_pst_ptr -> bj_pst.meters.n_calls_abort = 161 bjm_data_$bj_pst_ptr -> bj_pst.meters.n_calls_abort + 1; 162 163 /* validate transaction index and ID */ 164 165 call VALIDATE_TRANSACTION (); 166 167 /* if no record has been written this transaction, then don't now */ 168 169 if bj_txte.first_bj_rec_id = ZERO 170 then do; 171 bj_txte.ok_to_write = NO; 172 bj_txte.last_completed_operation = ABORTED; 173 goto bjm_wrap_up; 174 end; 175 176 /* make the before journal record and write it */ 177 178 call WRITE_ABORTED_MARK (); 179 180 /* go to common wrap up point */ 181 182 goto bjm_wrap_up; 183 184 /* 185* ************************************************************************ 186* ********** BEGIN bjm_write$before_image ********** 187* ************************************************************************ 188**/ 189 bjm_write$before_image: 190 entry (p_fm_uid, p_fm_oid, p_ci_no, p_ci_parts_ptr, p_bi_time_stamp, p_before_image_code); 191 192 /* copy parameters and identify self */ 193 194 fm_uid = p_fm_uid; 195 fm_oid = p_fm_oid; 196 ci_no = p_ci_no; 197 ci_parts_ptr = p_ci_parts_ptr; 198 txn_id = dm_data_$current_txn_id; 199 txn_index = dm_data_$current_txn_index; 200 201 p_before_image_code = 0; 202 203 my_name = BEFORE_IMAGE_ID; 204 return_code_ptr = addr (p_before_image_code); 205 206 /* invoke entry protocol common to all before_journal_manager_ */ 207 208 on cleanup call EMERGENCY_CLEANUP (); 209 210 call ENTER_BJM (); 211 212 /* meter */ 213 214 bjm_data_$bj_pst_ptr -> bj_pst.meters.n_calls_before_image = 215 bjm_data_$bj_pst_ptr -> bj_pst.meters.n_calls_before_image + 1; 216 217 /* validate transaction index and ID */ 218 219 call VALIDATE_TRANSACTION (); 220 221 /* make the before journal record and write it */ 222 223 call WRITE_BEFORE_IMAGE (); 224 225 /* go to common wrap up point */ 226 227 goto bjm_wrap_up; 228 229 /* 230* ************************************************************************ 231* ********** BEGIN bjm_write$committed_mark ******** 232* ************************************************************************ 233**/ 234 bjm_write$committed_mark: 235 entry (p_tid, p_tix, p_commit_code); 236 237 /* copy parameters and identify self */ 238 239 txn_id = p_tid; 240 txn_index = p_tix; 241 242 p_commit_code = 0; 243 244 my_name = COMMIT_ID; 245 return_code_ptr = addr (p_commit_code); 246 247 /* invoke entry protocol common to all before_journal_manager_ */ 248 249 on cleanup call EMERGENCY_CLEANUP (); 250 251 call ENTER_BJM (); 252 253 /* meter */ 254 255 bjm_data_$bj_pst_ptr -> bj_pst.meters.n_calls_commit = 256 bjm_data_$bj_pst_ptr -> bj_pst.meters.n_calls_commit + 1; 257 258 /* validate transaction index and ID */ 259 260 call VALIDATE_TRANSACTION (); 261 262 /* if no record has been written this transaction, then don't now */ 263 264 if bj_txte.first_bj_rec_id = ZERO 265 then do; 266 bj_txte.ok_to_write = NO; 267 bj_txte.last_completed_operation = COMMITTED; 268 goto bjm_wrap_up; 269 end; 270 271 /* make the before journal record and write it */ 272 273 call WRITE_COMMITTED_MARK (); 274 275 /* go to common wrap up point */ 276 277 goto bjm_wrap_up; 278 279 /* 280* ************************************************************************ 281* ********** BEGIN bjm_write$rolled_back_mark ****** 282* ************************************************************************ 283**/ 284 bjm_write$rolled_back_mark: 285 entry (p_tid, p_tix, p_checkpoint_no, p_rolled_back_code); 286 287 /* copy parameters and identify self */ 288 289 txn_id = p_tid; 290 txn_index = p_tix; 291 checkpoint_no = p_checkpoint_no; 292 293 p_rolled_back_code = 0; 294 295 my_name = ROLLED_BACK_ID; 296 return_code_ptr = addr (p_rolled_back_code); 297 298 /* invoke entry protocol common to all before_journal_manager_ */ 299 300 on cleanup call EMERGENCY_CLEANUP (); 301 302 call ENTER_BJM (); 303 304 /* meter */ 305 306 bjm_data_$bj_pst_ptr -> bj_pst.meters.n_calls_rb_mark = 307 bjm_data_$bj_pst_ptr -> bj_pst.meters.n_calls_rb_mark + 1; 308 309 /* validate transaction index and ID */ 310 311 call VALIDATE_TRANSACTION (); 312 313 /* if no record has been written this transaction, then don't now */ 314 315 if bj_txte.first_bj_rec_id = ZERO 316 then goto bjm_wrap_up; 317 318 /* make the before journal record and write it */ 319 320 call WRITE_ROLLED_BACK_MARK (); 321 322 /* go to common wrap up point */ 323 324 goto bjm_wrap_up; 325 326 /* 327* ************************************************************************ 328* ********** BEGIN bjm_write$fm_rollback_handler ********** 329* ************************************************************************ 330**/ 331 bjm_write$fm_rollback_handler: 332 entry (p_fm_uid, p_fm_oid, p_buff_ptr, p_buff_len, p_n_ci_held, p_fr_time_stamp, p_fm_rollback_code); 333 334 /* copy parameters and identify self */ 335 336 fm_uid = p_fm_uid; 337 fm_oid = p_fm_oid; 338 buff_ptr = p_buff_ptr; 339 buff_len = p_buff_len; 340 n_ci_held = p_n_ci_held; 341 txn_id = dm_data_$current_txn_id; 342 txn_index = dm_data_$current_txn_index; 343 344 p_fm_rollback_code = 0; 345 346 my_name = FM_ROLLBACK_HANDLER_ID; 347 return_code_ptr = addr (p_fm_rollback_code); 348 349 /* invoke entry protocol common to all before_journal_manager_ */ 350 351 on cleanup call EMERGENCY_CLEANUP (); 352 353 call ENTER_BJM (); 354 355 /* meter */ 356 357 bjm_data_$bj_pst_ptr -> bj_pst.meters.n_calls_fm_rbh = 358 bjm_data_$bj_pst_ptr -> bj_pst.meters.n_calls_fm_rbh + 1; 359 360 /* validate transaction index and ID */ 361 362 call VALIDATE_TRANSACTION (); 363 364 /* make then before journal record and write it */ 365 366 call WRITE_FM_ROLLBACK_HANDLER (); 367 368 /* go to common wrap up point */ 369 370 goto bjm_wrap_up; 371 372 /* 373* ************************************************************************ 374* ********** BEGIN bjm_write$fm_postcommit_handler ******** 375* ************************************************************************ 376**/ 377 bjm_write$fm_postcommit_handler: 378 entry (p_fm_uid, p_fm_oid, p_buff_ptr, p_buff_len, p_fm_postcommit_code); 379 380 /* copy parameters and identify self */ 381 382 fm_uid = p_fm_uid; 383 fm_oid = p_fm_oid; 384 buff_ptr = p_buff_ptr; 385 buff_len = p_buff_len; 386 txn_id = dm_data_$current_txn_id; 387 txn_index = dm_data_$current_txn_index; 388 389 p_fm_postcommit_code = 0; 390 391 my_name = FM_POSTCOMMIT_HANDLER_ID; 392 return_code_ptr = addr (p_fm_postcommit_code); 393 394 /* invoke entry protocol common to all before_journal_manager_ */ 395 396 on cleanup call EMERGENCY_CLEANUP (); 397 398 call ENTER_BJM (); 399 400 /* meter */ 401 402 bjm_data_$bj_pst_ptr -> bj_pst.meters.n_calls_fm_pc_mark = 403 bjm_data_$bj_pst_ptr -> bj_pst.meters.n_calls_fm_pc_mark + 1; 404 405 /* validate transaction index and ID */ 406 407 call VALIDATE_TRANSACTION (); 408 409 /* make then before journal record and write it */ 410 411 call WRITE_FM_POSTCOMMIT_HANDLER (); 412 413 /* go to common wrap up point */ 414 415 goto bjm_wrap_up; 416 417 /* standard bjm exit sequence, except to set return code */ 418 419 bjm_wrap_up: 420 bjm_data_$bj_exit_err = 421 bjm_data_$bj_default_error_label; 422 bjm_data_$bj_operation = ""; 423 424 bjm_return: 425 return; 426 427 bjm_nonlocal_error_exit: 428 code = bjm_data_$bj_code; 429 430 bjm_local_error_exit: 431 return_code = code; 432 call EMERGENCY_CLEANUP; 433 goto bjm_return; 434 435 436 /* BEGIN INTERNAL SUPPORT PROCEDURES */ 437 438 ENTER_BJM: /* procedure to execute standard */ 439 procedure (); /* bjm entry sequence */ 440 441 if bjm_data_$bj_operation = "" 442 then bjm_data_$bj_operation = my_name; 443 else do; 444 return_code = dm_error_$bj_recursive_invoc; 445 goto bjm_return; 446 end; 447 448 bjm_data_$bj_exit_err = bjm_nonlocal_error_exit; 449 bjm_data_$bj_code = 0; 450 451 return; 452 453 end ENTER_BJM; 454 455 VALIDATE_TRANSACTION: /* procedure to insure that state of the */ 456 procedure (); /* TXTE is consistent */ 457 458 /* get to TXT */ 459 460 bj_txt_ptr = dm_data_$bj_txt_ptr; 461 462 if bj_txt.version ^= BJ_TXT_VERSION_1 463 then do; 464 code = dm_error_$bj_bad_txt_version; 465 goto bjm_local_error_exit; 466 end; 467 468 /* validate transaction identifiers */ 469 470 if txn_index < 1 | txn_index > dm_system_data_$max_n_transactions | txn_id = ZERO 471 then do; 472 code = dm_error_$no_current_transaction; 473 goto bjm_local_error_exit; 474 end; 475 476 /* get to TXTE */ 477 478 bj_txte_ptr = addr (bj_txt.entry (txn_index)); 479 480 /* see if a write is pending */ 481 482 if bj_txte.append_state.current_operation ^= "" 483 then call bj_txte_util$synchronize_txte_pste (bj_txte_ptr); 484 485 if bj_txte.tid ^= txn_id 486 then do; 487 if bj_txte.tid ^= ZERO 488 then code = dm_error_$bj_bad_tid; 489 else code = dm_error_$no_current_transaction; 490 goto bjm_local_error_exit; 491 end; 492 493 /* have we been called by transaction_manager_ for the same operation twice? */ 494 495 if bj_txte.entry_state.ok_to_write = NO 496 then do; 497 if my_name = COMMIT_ID 498 then if bj_txte.last_completed_operation = COMMITTED 499 then code = 0; 500 else code = dm_error_$bj_cant_commit; 501 else if my_name = ABORT_ID 502 then if bj_txte.last_completed_operation = ABORTED 503 then code = 0; 504 else code = dm_error_$bj_cant_abort; 505 else code = dm_error_$no_current_transaction; 506 507 goto bjm_local_error_exit; 508 end; 509 510 /* after all is fine, find the PPTE */ 511 512 bj_ppte_ptr = bj_txte.ppte_ptr; 513 514 return; 515 516 end VALIDATE_TRANSACTION; 517 518 INITIALIZE_TRANSACTION: /* procedure to fill txte for new transaction */ 519 procedure (); 520 521 bj_txt_ptr = dm_data_$bj_txt_ptr; 522 bj_txte_ptr = addr (bj_txt.entry (txn_index)); 523 bj_ppte_ptr = bj_oid_util$get_ptr (bj_oid); 524 525 bj_txte.tid = ZERO; 526 bj_txte.bj_uid = bj_ppte.bj_uid; 527 528 bj_txte.entry_state.ok_to_write = NO; 529 530 bj_txte.owner_info.process_id = bjm_data_$bj_ppt_ptr -> bj_ppt.process_id; 531 532 bj_txte.operator_info.process_id = bj_txte.owner_info.process_id; 533 bj_txte.operator_info.ppte_ptr = bj_ppte_ptr; 534 bj_txte.operator_info.bj_oid = bj_oid; /* bj_oid must come from parameters */ 535 536 unspec (bj_txte.records_info) = ""b; 537 538 bj_txte.append_state.current_operation = ""; 539 540 bj_txte.tid = txn_id; 541 bj_txte.entry_state.last_completed_operation = BEGIN_MARK; 542 bj_txte.entry_state.ok_to_write = YES; 543 544 return; 545 546 end INITIALIZE_TRANSACTION; 547 548 WRITE_ABORTED_MARK: /* procedure to format aborted mark and */ 549 procedure (); /* forward it for writing in the journal */ 550 551 dcl 1 my_bj_aborted_record aligned like bj_aborted_rec; /* local copy of aborted mark */ 552 553 bj_rec_hdr_ptr = addr (my_bj_aborted_record); 554 555 bj_aborted_rec.type = BJ_RECORD_TYPE.ABORTED; 556 bj_aborted_rec.tid = txn_id; 557 bj_aborted_rec.process_id = bj_txte.owner_info.process_id; 558 bj_aborted_rec.prev_rec_id = bj_txte.last_bj_rec_id; 559 bj_aborted_rec.tx_rec_no = bj_txte.n_rec_written + 1; 560 n_rec_bytes = size (my_bj_aborted_record) * 4; 561 562 bj_txte.append_state.pending_bj_rec_id = ZERO; 563 bj_txte.append_state.pending_n_rec_written = bj_txte.records_info.n_rec_written + 1; 564 bj_txte.append_state.pending_n_bytes_written = bj_txte.records_info.n_bytes_written + n_rec_bytes; 565 566 call APPEND (addr (my_bj_aborted_record), n_rec_bytes, -1, 0); 567 call bj_txte_util$aborted_mark (bj_txte_ptr); 568 569 return; 570 571 end WRITE_ABORTED_MARK; 572 573 WRITE_BEFORE_IMAGE: /* procedure to format a before image and */ 574 procedure (); /* forward it for writing in the journal */ 575 576 dcl default_bj_before_image_space aligned char (1024); /* space to build small before image */ 577 dcl part_no fixed bin; /* ci part number */ 578 dcl part_len fixed bin; /* length of one ci_part, used for based variable one_ci_part */ 579 dcl one_ci_part char (part_len) based;/* image of the ci_part provided via parameters */ 580 581 /* if the before image is small enough, we will make it here; if not, grow a frame in which to put it */ 582 583 bj_rec_hdr_ptr = addr (default_bj_before_image_space); 584 bj_before_image.n_parts = 1; /* do this so next statement won't blow up */ 585 586 n_rec_bytes = (bin (rel (addr (bj_before_image.part (1)))) - 587 bin (rel (bj_rec_hdr_ptr))) * 4; /* length of constant portion of before image record in bytes */ 588 589 do part_no = 1 to ci_parts_ptr -> ci_parts.number_of_parts; 590 n_rec_bytes = n_rec_bytes + 8 + ci_parts_ptr -> ci_parts.part (part_no).length_in_bytes; 591 /* 8 = length of part.offset and part.length */ 592 end; 593 594 /* determine effect of adding this image to journal upon n_txn in journal */ 595 596 if bj_txte.last_bj_rec_id = ZERO 597 then delta_txn = 1; 598 else delta_txn = 0; 599 600 /* see if there is enough space in the internal buffer for the before image */ 601 602 if n_rec_bytes > 1024 603 then do; /* the bj_before_image_rec will be too big for default space */ 604 605 MAKE_LARGE_BEFORE_IMAGE: 606 begin; /* push a stack frame with enough room for before image */ 607 608 dcl bj_before_image_space aligned char (n_rec_bytes); 609 610 bj_rec_hdr_ptr = addr (bj_before_image_space); 611 612 call FILL_BEFORE_IMAGE (); 613 614 bj_txte.append_state.pending_bj_rec_id = ZERO; 615 bj_txte.append_state.pending_n_rec_written = bj_txte.records_info.n_rec_written + 1; 616 bj_txte.append_state.pending_n_bytes_written = bj_txte.records_info.n_bytes_written + n_rec_bytes; 617 618 call APPEND (bj_rec_hdr_ptr, n_rec_bytes, delta_txn, 1); 619 call bj_txte_util$before_image (bj_txte_ptr); 620 621 end MAKE_LARGE_BEFORE_IMAGE; 622 623 end; 624 625 else do; 626 627 call FILL_BEFORE_IMAGE (); 628 629 bj_txte.append_state.pending_bj_rec_id = ZERO; 630 bj_txte.append_state.pending_n_rec_written = bj_txte.records_info.n_rec_written + 1; 631 bj_txte.append_state.pending_n_bytes_written = bj_txte.records_info.n_bytes_written + n_rec_bytes; 632 633 call APPEND (bj_rec_hdr_ptr, n_rec_bytes, delta_txn, 1); 634 call bj_txte_util$before_image (bj_txte_ptr); 635 636 end; 637 638 /* more meters - here because the quantities are easiest obtained at this point */ 639 640 bj_pste_ptr = bj_ppte.bj_pste_ptr; 641 bj_pste.meters.n_bi_written = bj_pste.meters.n_bi_written + 1; 642 bj_pste.meters.n_bi_bytes_written = bj_pste.meters.n_bi_bytes_written + n_rec_bytes; 643 644 p_bi_time_stamp = time_stamp; 645 646 return; 647 648 FILL_BEFORE_IMAGE: 649 procedure (); 650 651 bj_before_image.header.type = BJ_RECORD_TYPE.BEFORE_IMAGE; 652 bj_before_image.header.tid = txn_id; 653 bj_before_image.header.process_id = bj_txte.owner_info.process_id; 654 bj_before_image.header.prev_rec_id = bj_txte.last_bj_rec_id; 655 bj_before_image.header.tx_rec_no = bj_txte.n_rec_written + 1; 656 657 bj_before_image.fm_uid = fm_uid; 658 bj_before_image.fm_oid = fm_oid; 659 bj_before_image.ci_no = ci_no; 660 bj_before_image.n_parts = ci_parts_ptr -> ci_parts.number_of_parts; 661 662 bj_before_image.image_len = 0; /* initialize running size of before image */ 663 664 do part_no = 1 to ci_parts_ptr -> ci_parts.number_of_parts; 665 bj_before_image.part (part_no).byte_offset = ci_parts_ptr -> ci_parts.part (part_no).offset_in_bytes; 666 part_len = ci_parts_ptr -> ci_parts.part (part_no).length_in_bytes; 667 bj_before_image.part (part_no).byte_length = part_len; 668 bj_before_image_len = bj_before_image.image_len + 1; 669 /* set this value for use in string copying later */ 670 bj_before_image.image_len = bj_before_image.image_len + part_len; 671 /* set this value to indicate the actual running size */ 672 substr (bj_before_image.image, bj_before_image_len, part_len) = 673 ci_parts_ptr -> ci_parts.part (part_no).local_ptr -> one_ci_part; 674 /* make a copy of the ci_part. notice that */ 675 /* bj_before_image_len is not being used */ 676 /* as the declarations imply */ 677 end; 678 679 return; 680 681 end FILL_BEFORE_IMAGE; 682 683 end WRITE_BEFORE_IMAGE; 684 685 WRITE_COMMITTED_MARK: 686 procedure (); 687 688 /* Procedure to format a committed mark and forward it for */ 689 /* writing in the before journal. If we have written a */ 690 /* BEGIN_COMMIT mark, then we simply call */ 691 /* bj_txte_util$complex_commit and be done with it. */ 692 /* Otherwise we see if we need to write a BEGIN_COMMIT or */ 693 /* simply a COMMIT and then call bj_txte_util. */ 694 695 dcl 1 my_bj_committed_record aligned like bj_committed_rec; 696 dcl commit_mark_delta_txn fixed bin; /* Effect on number of transactions in journal: */ 697 /* -1 for COMMIT means reduces number by 1, */ 698 /* 0 for BEGIN_COMMIT means has no effect. */ 699 700 bj_rec_hdr_ptr = addr (my_bj_committed_record); 701 702 if bj_txte.last_completed_operation = BJ_RECORD_TYPE.BEGIN_COMMIT then 703 call bj_txte_util$complex_commit (bj_txte_ptr); 704 else 705 DO_COMPLETE_COMMIT_MARK_OPERATION: do; 706 if bj_txte.last_fm_postcommit_handler_rec_id = ZERO 707 then do; 708 bj_committed_rec.type = BJ_RECORD_TYPE.COMMITTED; 709 commit_mark_delta_txn = -1; 710 end; 711 else do; 712 bj_committed_rec.type = BJ_RECORD_TYPE.BEGIN_COMMIT; 713 commit_mark_delta_txn = 0; 714 end; 715 bj_committed_rec.tid = txn_id; 716 bj_committed_rec.process_id = bj_txte.owner_info.process_id; 717 bj_committed_rec.prev_rec_id = bj_txte.last_bj_rec_id; 718 bj_committed_rec.tx_rec_no = bj_txte.n_rec_written + 1; 719 n_rec_bytes = size (my_bj_committed_record) * 4; 720 721 bj_txte.append_state.pending_bj_rec_id = ZERO; 722 bj_txte.append_state.pending_n_rec_written = bj_txte.records_info.n_rec_written + 1; 723 bj_txte.append_state.pending_n_bytes_written = bj_txte.records_info.n_bytes_written + n_rec_bytes; 724 725 call APPEND (addr (my_bj_committed_record), n_rec_bytes, commit_mark_delta_txn, 0); 726 if bj_txte.last_fm_postcommit_handler_rec_id = ZERO 727 then call bj_txte_util$simple_commit (bj_txte_ptr); 728 else call bj_txte_util$complex_commit (bj_txte_ptr); 729 730 end DO_COMPLETE_COMMIT_MARK_OPERATION; 731 732 733 return; 734 735 end WRITE_COMMITTED_MARK; 736 737 WRITE_ROLLED_BACK_MARK: /* procedure to format rolled_back mark and */ 738 procedure (); /* forward it for writing in the journal */ 739 740 dcl 1 my_bj_rolled_back_record aligned like bj_rolled_back_rec; /* local copy of rolled_back mark */ 741 742 bj_rec_hdr_ptr = addr (my_bj_rolled_back_record); 743 744 bj_rolled_back_rec.type = BJ_RECORD_TYPE.ROLLED_BACK; 745 bj_rolled_back_rec.tid = txn_id; 746 bj_rolled_back_rec.process_id = bj_txte.owner_info.process_id; 747 bj_rolled_back_rec.prev_rec_id = bj_txte.curr_checkpoint_rec_id; 748 bj_rolled_back_rec.checkpoint_no = 0; 749 bj_rolled_back_rec.last_rolled_back_rec_id = bj_txte.last_bj_rec_id; 750 bj_rolled_back_rec.tx_rec_no = 1; /* must calculate this when checkpoints are implemented */ 751 n_rec_bytes = size (my_bj_rolled_back_record) * 4; 752 753 bj_txte.append_state.pending_bj_rec_id = ZERO; 754 bj_txte.append_state.pending_n_rec_written = 1; 755 bj_txte.append_state.pending_n_bytes_written = n_rec_bytes; 756 757 call APPEND (addr (my_bj_rolled_back_record), n_rec_bytes, 0, 0); 758 call bj_txte_util$rolled_back_mark (bj_txte_ptr); 759 760 return; 761 762 end WRITE_ROLLED_BACK_MARK; 763 764 WRITE_FM_ROLLBACK_HANDLER: /* procedure to format fm rollback handler mark and */ 765 procedure (); /* forward it for writing in the journal */ 766 767 dcl handler_buffer aligned char (512); 768 dcl info_buffer char (buff_len) based (buff_ptr); 769 dcl fm_rollback_delta_n_txn fixed bin; 770 771 if bj_txte.last_bj_rec_id = ZERO 772 then fm_rollback_delta_n_txn = 1; 773 else fm_rollback_delta_n_txn = 0; 774 775 bj_rec_hdr_ptr = addr (handler_buffer); 776 777 bj_fm_handler_rec.type = BJ_RECORD_TYPE.FM_ROLLBACK_HANDLER; 778 bj_fm_handler_rec.tid = txn_id; 779 bj_fm_handler_rec.process_id = bj_txte.owner_info.process_id; 780 bj_fm_handler_rec.prev_rec_id = bj_txte.last_bj_rec_id; 781 bj_fm_handler_rec.prev_rec_byte_size = 0; /* not used */ 782 bj_fm_handler_rec.tx_rec_no = bj_txte.n_rec_written + 1; 783 784 bj_fm_handler_rec.fm_uid = fm_uid; 785 bj_fm_handler_rec.fm_oid = fm_oid; 786 bj_fm_handler_rec.prev_fm_handler_rec_id = ZERO; 787 bj_fm_handler_rec.info_len = buff_len; 788 789 bj_fm_handler_rec.info_bytes = buff_ptr -> info_buffer; 790 791 n_rec_bytes = (size (bj_rec_hdr) * 4) + 792 16 + /* size of constant portion of bj_fm_handler */ 793 buff_len; 794 795 bj_txte.append_state.pending_bj_rec_id = ZERO; 796 bj_txte.append_state.pending_n_rec_written = bj_txte.records_info.n_rec_written + 1; 797 bj_txte.append_state.pending_n_bytes_written = bj_txte.records_info.n_bytes_written + n_rec_bytes; 798 799 call APPEND (bj_rec_hdr_ptr, n_rec_bytes, fm_rollback_delta_n_txn, n_ci_held); 800 call bj_txte_util$fm_rollback_handler (bj_txte_ptr); 801 802 p_fr_time_stamp = time_stamp; 803 804 return; 805 806 end WRITE_FM_ROLLBACK_HANDLER; 807 808 WRITE_FM_POSTCOMMIT_HANDLER: /* procedure to format fm postcommit handler mark and */ 809 procedure (); /* forward it for writing in the journal */ 810 811 dcl handler_buffer aligned char (512); 812 dcl info_buffer char (buff_len) based (buff_ptr); 813 dcl fm_postcommit_delta_n_txn fixed bin; 814 815 if bj_txte.last_bj_rec_id = ZERO 816 then fm_postcommit_delta_n_txn = 1; 817 else fm_postcommit_delta_n_txn = 0; 818 819 bj_rec_hdr_ptr = addr (handler_buffer); 820 821 bj_fm_handler_rec.type = BJ_RECORD_TYPE.FM_POSTCOMMIT_HANDLER; 822 bj_fm_handler_rec.tid = txn_id; 823 bj_fm_handler_rec.process_id = bj_txte.owner_info.process_id; 824 bj_fm_handler_rec.prev_rec_id = bj_txte.last_bj_rec_id; 825 bj_fm_handler_rec.prev_rec_byte_size = 0; /* not used */ 826 bj_fm_handler_rec.tx_rec_no = bj_txte.n_rec_written + 1; 827 828 bj_fm_handler_rec.fm_uid = fm_uid; 829 bj_fm_handler_rec.fm_oid = fm_oid; 830 bj_fm_handler_rec.prev_fm_handler_rec_id = bj_txte.records_info.last_fm_postcommit_handler_rec_id; 831 bj_fm_handler_rec.info_len = buff_len; 832 833 bj_fm_handler_rec.info_bytes = buff_ptr -> info_buffer; 834 835 n_rec_bytes = (size (bj_rec_hdr) * 4) + 836 16 + /* size of constant portion of bj_fm_handler */ 837 buff_len; 838 839 /* bj_txte.append_state was verified quiesed previously: use it without checking */ 840 841 bj_txte.append_state.pending_bj_rec_id = ZERO; 842 bj_txte.append_state.pending_n_rec_written = bj_txte.records_info.n_rec_written + 1; 843 bj_txte.append_state.pending_n_bytes_written = bj_txte.records_info.n_bytes_written + n_rec_bytes; 844 845 call APPEND (bj_rec_hdr_ptr, n_rec_bytes, fm_postcommit_delta_n_txn, 0); 846 call bj_txte_util$fm_postcommit_handler (bj_txte_ptr); 847 848 return; 849 850 end WRITE_FM_POSTCOMMIT_HANDLER; 851 852 APPEND: /* procedure to write a record in the before journal */ 853 procedure (p_rec_ptr, p_n_bytes, p_delta_txn, p_delta_image); 854 855 dcl p_rec_ptr pointer; /* points to record to be written */ 856 dcl p_n_bytes fixed bin; /* size of record in bytes */ 857 dcl p_delta_txn fixed bin; /* effect this record has on number of txn in journal */ 858 dcl p_delta_image fixed bin (27); /* change in number of before images when record written */ 859 860 /* change append_state to WRITE_PENDING by setting current_operation */ 861 862 bj_txte.append_state.current_operation = p_rec_ptr -> bj_rec_hdr.type; 863 864 /* call upon external service routine to change append_state */ 865 866 call bj_storage_append (bj_txte.bj_oid, p_rec_ptr, p_n_bytes, 867 p_delta_txn, p_delta_image, 868 bj_txte.append_state.pending_bj_rec_id, time_stamp); 869 870 return; 871 872 end APPEND; 873 874 EMERGENCY_CLEANUP: /* procedure to reset bjm static storage */ 875 procedure (); 876 877 dcl cleanup_code fixed bin (35); /* local status code */ 878 879 call bj_cleanup_tables$handler (cleanup_code); 880 881 bjm_data_$bj_operation = ""; 882 bjm_data_$bj_exit_err = 883 bjm_data_$bj_default_error_label; 884 885 return; 886 887 end EMERGENCY_CLEANUP; 888 889 890 891 /* DECLARATIONS */ 892 893 /* Parameters - see description in program header comments */ 894 895 dcl p_tid bit (36) aligned parameter; 896 dcl p_tix fixed bin parameter; 897 dcl p_bj_oid bit (36) aligned parameter; 898 dcl p_checkpoint_no fixed bin (35) parameter; 899 dcl p_fm_uid bit (36) aligned parameter; 900 dcl p_fm_oid bit (36) aligned parameter; 901 dcl p_ci_no fixed bin (24) unsigned parameter; 902 dcl p_ci_parts_ptr pointer parameter; 903 dcl p_buff_ptr pointer parameter; 904 dcl p_buff_len fixed bin parameter; 905 dcl p_n_ci_held fixed bin (27) parameter; 906 dcl p_bi_time_stamp fixed bin (71) parameter; 907 dcl p_fr_time_stamp fixed bin (71) parameter; 908 dcl p_abort_code fixed bin (35) parameter; 909 dcl p_before_image_code fixed bin (35) parameter; 910 dcl p_begin_code fixed bin (35) parameter; 911 dcl p_commit_code fixed bin (35) parameter; 912 dcl p_rolled_back_code fixed bin (35) parameter; 913 dcl p_fm_rollback_code fixed bin (35) parameter; 914 dcl p_fm_postcommit_code fixed bin (35) parameter; 915 916 /* Automatic */ 917 918 dcl txn_id bit (36) aligned; /* copy of parameter */ 919 dcl txn_index fixed bin; /* copy of parameter */ 920 dcl bj_oid bit (36) aligned; /* copy of parameter */ 921 dcl checkpoint_no fixed bin (35); /* copy of parameter */ 922 dcl fm_uid bit (36) aligned; /* copy of parameter */ 923 dcl fm_oid bit (36) aligned; /* copy of parameter */ 924 dcl ci_no fixed bin (24) unsigned; /* copy of parameter */ 925 dcl buff_ptr pointer; /* copy of parameter */ 926 dcl buff_len fixed bin; /* copy of parameter */ 927 dcl n_ci_held fixed bin (27); /* copy of parameter */ 928 dcl time_stamp fixed bin (71); /* copy of parameter */ 929 dcl code fixed bin (35); /* local status code */ 930 dcl my_name char (32); /* ID of operation */ 931 dcl return_code_ptr pointer; /* pointer to current return code, set at each entrypoint */ 932 dcl n_rec_bytes fixed bin; /* number of bytes in record, including header */ 933 dcl delta_txn fixed bin; /* change in number of transaction in journal */ 934 935 /* Static, External */ 936 937 dcl dm_data_$current_txn_id bit (36) aligned external static; 938 dcl dm_data_$current_txn_index fixed bin external static; 939 dcl dm_data_$bj_txt_ptr pointer external static; 940 dcl bjm_data_$bj_ppt_ptr pointer external static; 941 dcl bjm_data_$bj_pst_ptr pointer external static; 942 dcl dm_error_$no_current_transaction fixed bin (35) external static; 943 dcl dm_error_$bj_bad_txt_version fixed bin (35) external static; 944 dcl dm_error_$bj_bad_tid fixed bin (35) external static; 945 dcl dm_error_$bj_recursive_invoc fixed bin (35) external static; 946 dcl dm_error_$bj_cant_abort fixed bin (35) external static; 947 dcl dm_error_$bj_cant_commit fixed bin (35) external static; 948 949 /* Based */ 950 951 dcl return_code fixed bin (35) based (return_code_ptr); /* overlays parameter return codes */ 952 953 /* Constant */ 954 955 dcl ABORT_ID char (32) internal static options (constant) 956 init ("write_aborted_mark"); 957 dcl BEFORE_IMAGE_ID char (32) internal static options (constant) 958 init ("write_before_image"); 959 dcl BEGIN_ID char (32) internal static options (constant) 960 init ("write_begin_mark"); 961 dcl COMMIT_ID char (32) internal static options (constant) 962 init ("write_committed_mark"); 963 dcl ROLLED_BACK_ID char (32) internal static options (constant) 964 init ("write_rolled_back_mark"); 965 dcl FM_ROLLBACK_HANDLER_ID char (32) internal static options (constant) 966 init ("write_fm_rollback_handler"); 967 dcl FM_POSTCOMMIT_HANDLER_ID char (32) internal static options (constant) 968 init ("write_fm_postcommit_handler"); 969 dcl ZERO bit (36) aligned internal static options (constant) 970 init ((36)"0"b); 971 dcl YES bit (1) aligned internal static options (constant) 972 init ("1"b); 973 dcl NO bit (1) aligned internal static options (constant) 974 init ("0"b); 975 976 /* Entry */ 977 978 dcl before_journal_manager_$get_default_bj entry (bit (36) aligned, fixed bin (35)); 979 dcl bj_storage_append entry (bit (36) aligned, ptr, fixed bin, fixed bin, fixed bin (27), bit (36) aligned, fixed bin (71)); 980 dcl bj_cleanup_tables$handler entry (fixed bin (35)); 981 dcl bj_oid_util$get_ptr entry (bit (36) aligned) returns (ptr); 982 dcl bj_txte_util$synchronize_txte_pste entry (ptr); 983 dcl bj_txte_util$before_image entry (ptr); 984 dcl bj_txte_util$aborted_mark entry (ptr); 985 dcl bj_txte_util$simple_commit entry (ptr); 986 dcl bj_txte_util$complex_commit entry (ptr); 987 dcl bj_txte_util$rolled_back_mark entry (ptr); 988 dcl bj_txte_util$fm_rollback_handler entry (ptr); 989 dcl bj_txte_util$fm_postcommit_handler entry (ptr); 990 991 /* Builtin */ 992 993 dcl addr builtin; 994 dcl bin builtin; 995 dcl rel builtin; 996 dcl size builtin; 997 dcl substr builtin; 998 dcl unspec builtin; 999 1000 /* Condition */ 1001 1002 dcl cleanup condition; 1003 1004 /* Include Files */ 1005 1006 1 1 /* BEGIN INCLUDE FILE dm_bj_global_error_info.incl.pl1 */ 1 2 1 3 /* Originally found in before journal primitives written by */ 1 4 /* A. Bensoussan. Gathered into an include file for ease of use. */ 1 5 /* See the bjm_data_.alm source for details of use. */ 1 6 1 7 /* HISTORY: 1 8*Written by Mike Pandolf, 07/14/82. 1 9*Modified: 1 10*12/06/83 by L. A. Newcomb: Renamed before_journal_manager_static_ to 1 11* bjm_data_ and moved some cells from dm_data_ to bjm_data_. 1 12**/ 1 13 1 14 /* format: style4,indattr,ifthenstmt,ifthen,^indcomtxt,idind33 */ 1 15 dcl bjm_data_$bj_operation char (32) external static; 1 16 1 17 dcl bjm_data_$bj_exit_err label variable external; 1 18 1 19 dcl bjm_data_$bj_code fixed bin (35) external; 1 20 1 21 dcl bjm_data_$bj_default_error_label label external static; 1 22 1 23 1 24 /* END INCLUDE FILE dm_bj_global_error_info.incl.pl1 */ 1007 1008 2 1 /* BEGIN INCLUDE FILE: dm_bj_ppt.incl.pl1 */ 2 2 /* 2 3*Layout of the per-process before journal table and entries. 2 4* 2 5*Written by Andre Bensoussan June/July 1982 2 6*Modified: 2 7*09/29/82 by Lee A. Newcomb: To make two default oid cells, pad ppte's 2 8* to account for all used space, and use dm_system_data_ for 2 9* determining dimension of bj_ppt.e. 2 10**/ 2 11 /* format: style4,indattr,idind33,^indcomtxt */ 2 12 2 13 dcl BJ_PPT_VERSION_1 fixed bin int static options (constant) init (1); 2 14 dcl BJ_PPTE_VERSION_1 fixed bin int static options (constant) init (1); 2 15 2 16 dcl bj_ppt_ptr ptr; 2 17 2 18 dcl 1 bj_ppt based (bj_ppt_ptr) aligned, 2 19 2 version fixed bin, 2 20 2 max_n_entries fixed bin, /* should be = dm_system_data_$bj_max_n_journals */ 2 21 2 n_entries_used fixed bin, /* # of BJs open in this process */ 2 22 2 highest_ix_used fixed bin, /* max. # of BJs ever opened in this process */ 2 23 2 default_bj, /* for selecting a txn def. BJ by write_before_mark protocol */ 2 24 3 user_set_oid bit (36), /* explicit user setting via $set_default_bj */ 2 25 3 last_opened_oid bit (36), /* implicit if no user setting, set by open and close */ 2 26 /* if both zero, use system default BJ */ 2 27 2 process_id bit (36), /* so we don't have to keep calling for it. */ 2 28 2 process_ix fixed bin, /* index into bj_check_in_table */ 2 29 2 mod_list_area (100) fixed bin (35), /* for keeping track of ppt mods, not curr. used */ 2 30 2 31 2 e dim (dm_system_data_$bj_max_n_journals refer (bj_ppt.max_n_entries)) 2 32 like bj_ppte; /* an entry for each BJ open in this process */ 2 33 /* always make sure bj_ppt.e is on a even word boundary */ 2 34 2 35 /* now specify the format of each per-process BJ table entry */ 2 36 2 37 dcl bj_ppte_ptr ptr; 2 38 2 39 dcl 1 bj_ppte based (bj_ppte_ptr) aligned, 2 40 2 version fixed bin, /* better be the same for all entries in a bj_ppt */ 2 41 2 bj_uid bit (36), /* UID of the BJ page file */ 2 42 2 pf_oid bit (36), /* OID of the BJ page file */ 2 43 2 n_opening fixed bin, /* how many openings this process has done for this BJ */ 2 44 2 bj_pste_ptr ptr, /* "link" to per-system BJ table entry */ 2 45 2 open_time fixed bin (71); /* used to fill in bj_ppt.default_bj.last_opened_oid */ 2 46 /* if the last opened BJ is closed */ 2 47 2 48 /* END INCLUDE FILE: bj_ppt.incl.pl1 */ 1009 1010 3 1 /* BEGIN INCLUDE FILE: dm_bj_txt.incl.pl1 */ 3 2 /* 3 3*dm_bj_txt - before journal per-system transaction table. 3 4* 3 5*Designed by A. Bensoussan 3 6*Written by M. Pandolf 06/02/82 3 7*Modified: 3 8*10/01/82 by Lee A. Newcomb: To use dm_system_data_ for dimension attributes 3 9* and specify alignment on level one. 3 10*08feb83 by M. Pandolf: To restructure the TXT and TXTE. 3 11*30mar83 by M. Pandolf: To add last_completed_operation and ok_to_write. 3 12**/ 3 13 /* format: style4,indattr,idind33,^indcomtxt */ 3 14 3 15 dcl BJ_TXT_VERSION_1 fixed bin int static options (constant) init (1); 3 16 3 17 dcl bj_txt_ptr ptr; /* pointer to transaction table */ 3 18 dcl bj_txte_ptr ptr; /* pointer to transaction table element */ 3 19 3 20 dcl 1 bj_txt aligned based (bj_txt_ptr), /* transaction table */ 3 21 2 version fixed bin, /* should be BJ_TXT_VERSION_1 */ 3 22 2 max_n_entries fixed bin, 3 23 2 n_entries_used fixed bin, /* assumed contiguous */ 3 24 2 pad_header_to_32_words bit (36) dim (29), /* to mod32 align bj_txt.entry */ 3 25 2 entry dim (dm_system_data_$max_n_transactions refer (bj_txt.max_n_entries)) 3 26 like bj_txte; 3 27 3 28 dcl 1 bj_txte based (bj_txte_ptr) aligned, /* single entry, must be mod32 word aligned */ 3 29 2 tid bit (36), /* transaction id if this or last txn */ 3 30 2 bj_uid bit (36), /* UID of before journal chosen at begin mark */ 3 31 2 entry_state aligned, 3 32 3 last_completed_operation char (4), /* to prevent multiple abort and commit */ 3 33 3 ok_to_write bit (1), /* basically validates using this entry */ 3 34 2 owner_info aligned, /* info about creation of txte */ 3 35 3 process_id bit (36), /* of process that wrote begin mark */ 3 36 2 operator_info aligned, /* of process that is currently using this txte */ 3 37 3 process_id bit (36), /* of process that shall write subsequent marks */ 3 38 3 ppte_ptr ptr, /* pointer to PPTE for this transaction */ 3 39 3 bj_oid bit (36), /* before journal opening ID for operator */ 3 40 2 records_info aligned, /* grouped to be saved and restored as one unit */ 3 41 3 curr_checkpoint_rec_id bit (36), /* ident of checkpoint record if doing a rollback, */ 3 42 /* else, this value must be zero. */ 3 43 3 first_bj_rec_id bit (36), /* ident of first mark for this transaction */ 3 44 3 last_bj_rec_id bit (36), /* ident of current mark for this transaction */ 3 45 3 n_rec_written fixed bin (35), /* count of marks written for this transaction */ 3 46 3 n_bytes_written fixed bin (35), /* count of total bytes written to journal */ 3 47 3 last_fm_postcommit_handler_rec_id 3 48 bit (36), /* ident of last special handler in list */ 3 49 2 append_state aligned, /* the first two members define the state of this */ 3 50 3 current_operation char (4), /* transaction and its interaction with bj_storage: */ 3 51 3 pending_bj_rec_id bit (36), /* operation rec_id state */ 3 52 /* *null* XXX quiesed */ 3 53 /* ^null "0"b write pending */ 3 54 /* ^null ^"0"b write completed, needs flushing */ 3 55 /* */ 3 56 3 pending_n_rec_written fixed bin (35), /* copy to n_rec_written before flush */ 3 57 3 pending_n_bytes_written fixed bin (35), /* copy to n_bytes_written before flush */ 3 58 2 pad_entry_to_32_words bit (36) dim (13); /* make any part of table 32 words long */ 3 59 3 60 /* END INCLUDE FILE: dm_bj_txt_ptr */ 1011 1012 4 1 /* BEGIN dm_bj_static.incl.pl1 */ 4 2 /* 4 3*Modified: 4 4*10/04/82 by Lee A. Newcomb: To change from internal static to external 4 5* static. 4 6**/ 4 7 4 8 dcl dm_system_data_$bj_max_n_journals fixed bin ext static; 4 9 dcl dm_system_data_$bj_max_n_processes fixed bin ext static; 4 10 dcl dm_system_data_$max_n_transactions fixed bin ext static; 4 11 4 12 /* END dm_bj_static.incl.pl1 */ 4 13 1013 1014 5 1 /* format: style4,indattr,idind33,^indcomtxt */ 5 2 5 3 /* BEGIN INCLUDE FILE: dm_bj_records.incl.pl1 */ 5 4 /* 5 5*Before journal records - images and marks 5 6* 5 7*Designed by Andre Bensoussan 02/03/82 5 8*Written by Mike Pandolf 07/07/82 5 9*Modified: 5 10*10/01/82 by Lee A. Newcomb: To add n_txn to all records so rollback after 5 11* crash knows how many transactions were active at crash time. 5 12*15feb83 by M. Pandolf: To add fm_handler_rec for both rollback and postcommit 5 13* handler used exclusively by file_manager_, add BEGIN_COMMIT mark, 5 14* and add PREFORM_BEGIN mark (for housekeeping, never written). 5 15*05apr83 by M. Pandolf to add BEGIN_MARK for bj_txte.last_completed_operation 5 16**/ 5 17 5 18 5 19 dcl bj_rec_hdr_ptr ptr; /* pointer to various bj records */ 5 20 5 21 dcl 1 bj_rec_hdr aligned based (bj_rec_hdr_ptr), 5 22 2 type char (4), /* see types below */ 5 23 2 tid bit (36), /* transaction id for this record */ 5 24 2 process_id bit (36), /* of process initiating this transaction */ 5 25 2 prev_rec_id bit (36), /* of record in this transaction */ 5 26 2 prev_rec_byte_size fixed bin (24), /* of record in this transaction */ 5 27 2 tx_rec_no fixed bin (35), /* number of this record in transaction list */ 5 28 2 n_txn fixed bin; /* number of active txn's in the BJ containing this txn */ 5 29 /* with at least one record written in the BJ. This is */ 5 30 /* used for rollback after crash */ 5 31 /* N.B. commits and abort marks do not count themselves */ 5 32 5 33 /* before journal records for the various record types */ 5 34 5 35 dcl 1 bj_committed_rec aligned like bj_rec_hdr based (bj_rec_hdr_ptr); 5 36 5 37 dcl 1 bj_begin_commit_rec aligned like bj_rec_hdr based (bj_rec_hdr_ptr); 5 38 5 39 dcl 1 bj_aborted_rec aligned like bj_rec_hdr based (bj_rec_hdr_ptr); 5 40 5 41 dcl 1 bj_rolled_back_rec aligned based (bj_rec_hdr_ptr), 5 42 2 header like bj_rec_hdr, 5 43 2 checkpoint_no fixed bin (35), 5 44 2 last_rolled_back_rec_id bit (36); 5 45 5 46 dcl 1 bj_rollback_handler_rec aligned based (bj_rec_hdr_ptr), 5 47 2 header like bj_rec_hdr, 5 48 2 name_len fixed bin (24), 5 49 2 info_len fixed bin (24), 5 50 2 proc_name char (bj_rollback_name_len refer (bj_rollback_handler_rec.name_len)), 5 51 2 info_bits bit (bj_rollback_info_len refer (bj_rollback_handler_rec.info_len)); 5 52 5 53 /* dm_bj_records.incl.pl1 CONTINUED NEXT PAGE */ 5 54 5 55 /* dm_bj_records.incl.pl1 CONTINUATION FROM PREVIOUS PAGE */ 5 56 5 57 dcl 1 bj_before_image aligned based (bj_rec_hdr_ptr), 5 58 2 header like bj_rec_hdr, 5 59 2 fm_uid bit (36), 5 60 2 fm_oid bit (36), 5 61 2 ci_no fixed bin (35), 5 62 2 n_parts fixed bin (17), 5 63 2 image_len fixed bin (24), 5 64 2 part dim (bj_before_image_n_parts refer (bj_before_image.n_parts)), 5 65 3 byte_offset fixed bin (24), 5 66 3 byte_length fixed bin (24), 5 67 2 image char (bj_before_image_len refer (bj_before_image.image_len)); 5 68 5 69 dcl 1 bj_fm_handler_rec aligned based (bj_rec_hdr_ptr), 5 70 2 header like bj_rec_hdr, 5 71 2 fm_uid bit (36), 5 72 2 fm_oid bit (36), 5 73 2 prev_fm_handler_rec_id bit (36), 5 74 2 info_len fixed bin, 5 75 2 info_bytes char (bj_fm_handler_info_len refer (bj_fm_handler_rec.info_len)); 5 76 5 77 /* extent definers */ 5 78 5 79 dcl bj_rollback_name_len fixed bin (24); 5 80 dcl bj_rollback_info_len fixed bin (24); 5 81 dcl bj_before_image_n_parts fixed bin; 5 82 dcl bj_before_image_len fixed bin (24); 5 83 dcl bj_fm_handler_info_len fixed bin (24); 5 84 5 85 /* record type identifiers */ 5 86 5 87 dcl 1 BJ_RECORD_TYPE int static options (constant) aligned, 5 88 ( 2 BEGIN_COMMIT init ("bcom"), 5 89 2 PERFORM_COMMIT init ("pcom"), 5 90 2 COMMITTED init ("comm"), 5 91 2 ABORTED init ("abor"), 5 92 2 ROLLED_BACK init ("roll"), 5 93 2 HANDLER init ("hand"), 5 94 2 FM_ROLLBACK_HANDLER init ("fmrb"), 5 95 2 FM_POSTCOMMIT_HANDLER init ("fmpc"), 5 96 2 BEGIN_MARK init ("begi"), 5 97 2 BEFORE_IMAGE init ("befo")) char (4); 5 98 5 99 /* END INCLUDE FILE: dm_bj_records.incl.pl1 */ 1015 1016 6 1 /* BEGIN INCLUDE FILE: dm_ci_parts.incl.pl1 */ 6 2 6 3 /* DESCRIPTION: 6 4* 6 5* This include file contains the ci_parts structure. This structure 6 6* is used across the file_manager_ interface to specify the parts of a 6 7* control interval to get or put. If the number_of parts is equal to 0, 6 8* modules which take ci_parts interpret this case to mean to do everything 6 9* except the actual requested operation, i.e., lock the control interval 6 10* but don't get anything. offset_in_bytes is the 0-originned offset in 6 11* bytes from the beginning of the addressable portion of the control interval. 6 12* An offset_in_bytes which is in the addressable portion is in error. 6 13* Likewise, if offset_in_bytes + length_in_bytes is outside of the addressable 6 14* portion, it is in error. 6 15**/ 6 16 6 17 /* HISTORY: 6 18*Written by Matthew Pierret, 01/28/82. 6 19* (01/28/82 Andre Bensoussan, Design.) 6 20*Modified: 6 21*11/07/84 by Matthew Pierret: To add must_be_zero, initial attributes on 6 22* automatic storge. 6 23**/ 6 24 6 25 /* format: style2,ind3 */ 6 26 6 27 dcl 1 ci_parts aligned based (ci_parts_ptr), 6 28 2 number_of_parts fixed bin (17), 6 29 2 must_be_zero fixed bin, 6 30 2 part (cip_number_of_parts refer (ci_parts.number_of_parts)), 6 31 3 offset_in_bytes fixed bin (17), 6 32 3 length_in_bytes fixed bin (17), 6 33 3 local_ptr ptr; 6 34 6 35 dcl ci_parts_ptr ptr init (null ()); 6 36 dcl cip_number_of_parts fixed bin (17) init (0); 6 37 6 38 6 39 /* BEGIN INCLUDE FILE: dm_ci_parts.incl.pl1 */ 1017 1018 7 1 /* BEGIN INCLUDE FILE: dm_bj_pst.incl.pl1 */ 7 2 /* 7 3*Layout of the before journal per-system table header and BJ table entries. 7 4* 7 5*Written by Andre Bensoussan 06-15-1982 7 6*Modified: 7 7*09/29/82 by Lee A. Newcomb: To use dm_system_data_ for determining 7 8* dimension of bj_pst.e and force bj_pst.mod_list_area and 7 9* bj_pst.e to even word boundaries. 7 10*04/27/82 by M. Pandolf: To add meter space by cutting away from mod_list_area. 7 11**/ 7 12 /* format: style4,indattr,idind33,^indcomtxt */ 7 13 7 14 dcl BJ_PST_VERSION_1 fixed bin internal static options (constant) init (1); 7 15 7 16 dcl bj_pst_ptr ptr; 7 17 7 18 dcl 1 bj_pst based (bj_pst_ptr) aligned, 7 19 2 version fixed bin, 7 20 2 pad1 bit (36), 7 21 2 lock, 7 22 3 pid bit (36), /* process_id holding lock */ 7 23 3 event bit (36), 7 24 2 time_of_bootload fixed bin (71), /* for ease of access */ 7 25 2 max_n_entries fixed bin, /* as determined from dm_system_data_$bj_max_n_journals */ 7 26 2 n_entries_used fixed bin, /* current # of BJs open on the system */ 7 27 2 highest_ix_used fixed bin, /* max. # of BJs that has ever been open of the system */ 7 28 2 pn_table_offset fixed bin (18) uns, /* relative offset of bj_pn_table in bj_pst seg. */ 7 29 2 check_in_table_offset fixed bin (18) uns, /* ditto for bj_check_in_table */ 7 30 2 buffer_table_offset fixed bin (18) uns, /* ditto for where our BJ buffers are located */ 7 31 2 max_n_buffers fixed bin, /* must be <= to max_n_entries */ 7 32 2 pad2 bit (36), /* force next on even word boundary */ 7 33 2 meters, /* dim (50) fixed bin (71), */ 7 34 3 n_calls_begin_txn fixed bin (71), /* meter (1) */ 7 35 3 n_calls_before_image fixed bin (71), /* meter (2) */ 7 36 3 n_calls_abort fixed bin (71), /* meter (3) */ 7 37 3 n_calls_commit fixed bin (71), /* meter (4) */ 7 38 3 n_calls_rb_mark fixed bin (71), /* meter (5) */ 7 39 3 n_calls_fm_pc_mark fixed bin (71), /* meter (6) */ 7 40 3 n_calls_fm_rbh fixed bin (71), /* meter (7) */ 7 41 3 n_calls_rollback fixed bin (71), /* meter (8) */ 7 42 3 meter dim (9:50) fixed bin (71), /* meter (9) - meter (50) */ 7 43 2 mod_list_area (100) fixed bin (35), /* for keeping track of pst mods */ 7 44 7 45 2 e dim (dm_system_data_$bj_max_n_journals refer (bj_pst.max_n_entries)) 7 46 like bj_pste; /* per system BJ table entries */ 7 47 7 48 7 49 /* END INCLUDE FILE: dm_bj_pst.incl.pl1 */ 1019 1020 8 1 /* BEGIN INCLUDE FILE: dm_bj_pste.incl.pl1 */ 8 2 8 3 /* DESCRIPTION 8 4* 8 5* Layout of the per-system before journal table 8 6* entries. This structure is used to contain information 8 7* about a before journal active in a running DMS. It is 8 8* currently also used as the header of a before journal 8 9* (see dm_bj_header.incl.pl1). Version changes to this 8 10* structure require either automatic conversion to be set 8 11* up, or users to be told to re-create their journals. 8 12* 8 13* Currently, a bj_pste must be 64 words long; any 8 14* future changes must at least make sure a bj_pste is an 8 15* even # of words for the alignment of some of its 8 16* elements. 8 17**/ 8 18 8 19 /* HISTORY: 8 20* 8 21*Written by Andre Bensoussan, 06/15/82. 8 22*Modified: 8 23*08/16/82 by Andre Bensoussan: to add stamp_for_last_ci_put. 8 24*09/29/82 by Lee A. Newcomb: to fix BJ_PSTE_VERSION_1 and fix some 8 25* alignments. 8 26*11/01/82 by Andre Bensoussan: to add "stamp_for_last_ci_on_disk", 8 27* "n_bi_still_unsafe", and "n_bi_being_saved". 8 28*02/08/83 by M. Pandolf: to add append_state structure. 8 29*03/19/83 by L. A. Newcomb: to fix up some alignments and spelling problems. 8 30*04/27/83 by M. Pandolf: to add meter structure at end. 8 31*02/11/85 by Lee A. Newcomb: Fixed version constant name to agree with its 8 32* value of 2; fixed references to page files or PF's; fixed format 8 33* of description and history sections. 8 34*03/07/85 by Lee A. Newcomb: Changed a pad word to be txn_storage_limit and 8 35* expanded on the description for future generations (no 8 36* version was made). 8 37*03/27/85 by Lee A. Newcomb: Changed one of the unused meters to 8 38* n_txn_storage_limit_hits (again without a version change). 8 39**/ 8 40 /* format: style2,ll79,ind3,^indprocbody,ifthendo,ifthen,^indnoniterdo,^inddcls,dclind5,idind35,linecom */ 8 41 8 42 dcl BJ_PSTE_VERSION_2 fixed bin internal static 8 43 options (constant) init (2); 8 44 8 45 dcl bj_pste_ptr ptr; 8 46 8 47 /* MUST HAVE EVEN NUMBER OR WORDS */ 8 48 dcl 1 bj_pste based (bj_pste_ptr) aligned, 8 49 2 version fixed bin, 8 50 2 bj_ix fixed bin, /* Index of this entry in bj_pst table */ 8 51 2 lock aligned, 8 52 3 pid bit (36), /* process ID of lock owner */ 8 53 3 event bit (36), 8 54 2 bj_uid bit (36), /* UID of BJ file */ 8 55 2 ci_size fixed bin, /* In number of bytes */ 8 56 2 max_size fixed bin, /* In number of ci's */ 8 57 2 active bit (1) aligned, /* 0 means journal not being used */ 8 58 2 time_header_updated fixed bin (71), 8 59 2 earliest_meaningful_time fixed bin (71), /* time stamp on first valid control interval */ 8 60 2 update_frequency fixed bin, /* Not used yet, probably will be how many CIs */ 8 61 2 last_rec_id bit (36), /* rec id of the last logical record in journal */ 8 62 2 n_processes fixed bin, /* Number of processes using this BJ */ 8 63 2 n_txn fixed bin, /* Number of txn in progress using this BJ */ 8 64 2 last_ci_info aligned, 8 65 3 last_ci_buffered fixed bin (24) uns, /* Last ci encached in the buffer */ 8 66 3 last_ci_put fixed bin (24) uns, /* Last ci put in the BJ */ 8 67 3 last_ci_flushed fixed bin (24) uns, /* Last ci for which flush initiated */ 8 68 3 last_ci_on_disk fixed bin (24) uns, /* Last ci of that portion of the BJ known to be ... */ 8 69 /* .. completely on disk */ 8 70 3 stamp_for_last_ci_put fixed bin (71), /* Time stamp associated with the last ci put in the BJ */ 8 71 3 stamp_for_last_ci_on_disk fixed bin (71), /* Time stamp associated with the last ci on disk in the BJ */ 8 72 2 n_bi_still_unsafe fixed bin, /* number of bi's still not on disk */ 8 73 2 n_bi_being_saved fixed bin, /* number of bi's for which flush initiated */ 8 74 2 buffer_offset fixed bin (18) uns, /* Now allocated in the bj_pst segment */ 8 75 2 txn_storage_limit fixed bin (35), /* # of bytes a single txn may write */ 8 76 2 cl aligned, /* Circular List */ 8 77 3 origin_ci fixed bin (24) uns, 8 78 3 lowest_ci fixed bin (24) uns, 8 79 3 highest_ci fixed bin (24) uns, 8 80 3 number_ci fixed bin (24) uns, 8 81 2 append_state aligned, 8 82 3 current_operation char (4), /* equal to "appe" when append in progress */ 8 83 3 pending_n_txn fixed bin, /* n_txn value when append done */ 8 84 3 pending_last_rec_id bit (36), /* last_rec_id value after append done */ 8 85 3 pending_last_element_id bit (36), /* last element id after append done */ 8 86 3 txte_rec_id_relp bit (18), /* rel ptr into seg containing TXT for txte.pending_bj_rec_id */ 8 87 2 pad_to_even_word1 bit (36) aligned, 8 88 2 meters aligned, /* dim (10) fixed bin (71), */ 8 89 3 n_bi_written fixed bin (71), /* meter (1) */ 8 90 3 n_bi_bytes_written fixed bin (71), /* meter (2) */ 8 91 3 n_journal_full fixed bin (71), /* meter (3) */ 8 92 3 n_successful_recycles fixed bin (71), /* meter (4) */ 8 93 3 n_ci_recycled fixed bin (71), /* meter (5) */ 8 94 3 n_txn_started fixed bin (71), /* meter (6) */ 8 95 3 n_non_null_txn fixed bin (71), /* meter (7) */ 8 96 3 n_txn_storage_limit_hits fixed bin (71), /* meter (8) */ 8 97 3 meter (9:10) fixed bin (71), 8 98 /* meter (9) - meter (10) */ 8 99 2 pad_to_64_words (6) bit (36); /* 64 is even (see below) */ 8 100 8 101 8 102 /* END INCLUDE FILE: dm_bj_pste.incl.pl1 */ 1021 1022 1023 1024 end bjm_write$begin_mark; SOURCE FILES USED IN THIS COMPILATION. LINE NUMBER DATE MODIFIED NAME PATHNAME 0 04/04/85 0826.3 bjm_write.pl1 >spec>on>7192.pbf-04/04/85>bjm_write.pl1 1007 1 01/07/85 0857.3 dm_bj_global_error_info.incl.pl1 >ldd>include>dm_bj_global_error_info.incl.pl1 1009 2 01/07/85 0857.6 dm_bj_ppt.incl.pl1 >ldd>include>dm_bj_ppt.incl.pl1 1011 3 01/07/85 0858.0 dm_bj_txt.incl.pl1 >ldd>include>dm_bj_txt.incl.pl1 1013 4 01/07/85 0857.8 dm_bj_static.incl.pl1 >ldd>include>dm_bj_static.incl.pl1 1015 5 01/07/85 0857.7 dm_bj_records.incl.pl1 >ldd>include>dm_bj_records.incl.pl1 1017 6 01/07/85 0900.8 dm_ci_parts.incl.pl1 >ldd>include>dm_ci_parts.incl.pl1 1019 7 01/07/85 0857.7 dm_bj_pst.incl.pl1 >ldd>include>dm_bj_pst.incl.pl1 1021 8 04/04/85 0819.1 dm_bj_pste.incl.pl1 >spec>on>7192.pbf-04/04/85>dm_bj_pste.incl.pl1 NAMES DECLARED IN THIS COMPILATION. IDENTIFIER OFFSET LOC STORAGE CLASS DATA TYPE ATTRIBUTES AND REFERENCES (* indicates a set context) NAMES DECLARED BY DECLARE STATEMENT. ABORTED 3 000000 constant char(4) initial level 2 dcl 5-87 ref 172 501 555 ABORT_ID 000072 constant char(32) initial unaligned dcl 955 ref 149 501 BEFORE_IMAGE 11 000000 constant char(4) initial level 2 dcl 5-87 ref 651 BEFORE_IMAGE_ID 000062 constant char(32) initial unaligned dcl 957 ref 203 BEGIN_COMMIT 000000 constant char(4) initial level 2 dcl 5-87 ref 702 712 BEGIN_ID 000052 constant char(32) initial unaligned dcl 959 ref 100 BEGIN_MARK 10 000000 constant char(4) initial level 2 dcl 5-87 ref 541 BJ_RECORD_TYPE 000000 constant structure level 1 dcl 5-87 BJ_TXT_VERSION_1 constant fixed bin(17,0) initial dcl 3-15 ref 462 COMMITTED 2 000000 constant char(4) initial level 2 dcl 5-87 ref 267 497 708 COMMIT_ID 000042 constant char(32) initial unaligned dcl 961 ref 244 497 FM_POSTCOMMIT_HANDLER 7 000000 constant char(4) initial level 2 dcl 5-87 ref 821 FM_POSTCOMMIT_HANDLER_ID 000012 constant char(32) initial unaligned dcl 967 ref 391 FM_ROLLBACK_HANDLER 6 000000 constant char(4) initial level 2 dcl 5-87 ref 777 FM_ROLLBACK_HANDLER_ID 000022 constant char(32) initial unaligned dcl 965 ref 346 NO constant bit(1) initial dcl 973 ref 171 266 495 528 ROLLED_BACK 4 000000 constant char(4) initial level 2 dcl 5-87 ref 744 ROLLED_BACK_ID 000032 constant char(32) initial unaligned dcl 963 ref 295 YES constant bit(1) initial dcl 971 ref 542 ZERO constant bit(36) initial dcl 969 ref 105 169 264 315 470 487 525 562 596 614 629 706 721 726 753 771 786 795 815 841 addr builtin function dcl 993 ref 101 150 204 245 296 347 392 478 522 553 566 566 583 586 610 700 725 725 742 757 757 775 819 append_state 21 based structure level 2 dcl 3-28 before_journal_manager_$get_default_bj 000036 constant entry external dcl 978 ref 108 bin builtin function dcl 994 ref 586 586 bj_aborted_rec based structure level 1 dcl 5-39 bj_before_image based structure level 1 dcl 5-57 bj_before_image_len 000152 automatic fixed bin(24,0) dcl 5-82 set ref 668* 672 bj_before_image_space 000100 automatic char dcl 608 set ref 610 bj_cleanup_tables$handler 000042 constant entry external dcl 980 ref 879 bj_committed_rec based structure level 1 dcl 5-35 bj_fm_handler_rec based structure level 1 dcl 5-69 bj_oid 12 based bit(36) level 3 in structure "bj_txte" dcl 3-28 in procedure "bjm_write$begin_mark" set ref 534* 866* bj_oid 000102 automatic bit(36) dcl 920 in procedure "bjm_write$begin_mark" set ref 105* 108* 523* 534 bj_oid_util$get_ptr 000044 constant entry external dcl 981 ref 523 bj_ppt based structure level 1 dcl 2-18 bj_ppte based structure level 1 dcl 2-39 bj_ppte_ptr 000142 automatic pointer dcl 2-37 set ref 127 127 512* 523* 526 533 640 bj_pst based structure level 1 dcl 7-18 bj_pste based structure level 1 dcl 8-48 bj_pste_ptr 000160 automatic pointer dcl 8-45 in procedure "bjm_write$begin_mark" set ref 640* 641 641 642 642 bj_pste_ptr 4 based pointer level 2 in structure "bj_ppte" dcl 2-39 in procedure "bjm_write$begin_mark" ref 127 127 640 bj_rec_hdr based structure level 1 dcl 5-21 ref 791 835 bj_rec_hdr_ptr 000150 automatic pointer dcl 5-19 set ref 553* 555 556 557 558 559 583* 584 586 586 610* 618* 633* 651 652 653 654 655 657 658 659 660 662 665 667 668 670 670 672 700* 708 712 715 716 717 718 742* 744 745 746 747 748 749 750 775* 777 778 779 780 781 782 784 785 786 787 789 791 799* 819* 821 822 823 824 825 826 828 829 830 831 833 835 845* bj_rolled_back_rec based structure level 1 dcl 5-41 bj_storage_append 000040 constant entry external dcl 979 ref 866 bj_txt based structure level 1 dcl 3-20 bj_txt_ptr 000144 automatic pointer dcl 3-17 set ref 460* 462 478 521* 522 bj_txte based structure level 1 dcl 3-28 bj_txte_ptr 000146 automatic pointer dcl 3-18 set ref 169 171 172 264 266 267 315 478* 482 482* 485 487 495 497 501 512 522* 525 526 528 530 532 532 533 534 536 538 540 541 542 557 558 559 562 563 563 564 564 567* 596 614 615 615 616 616 619* 629 630 630 631 631 634* 653 654 655 702 702* 706 716 717 718 721 722 722 723 723 726 726* 728* 746 747 749 753 754 755 758* 771 779 780 782 795 796 796 797 797 800* 815 823 824 826 830 841 842 842 843 843 846* 862 866 866 bj_txte_util$aborted_mark 000052 constant entry external dcl 984 ref 567 bj_txte_util$before_image 000050 constant entry external dcl 983 ref 619 634 bj_txte_util$complex_commit 000056 constant entry external dcl 986 ref 702 728 bj_txte_util$fm_postcommit_handler 000064 constant entry external dcl 989 ref 846 bj_txte_util$fm_rollback_handler 000062 constant entry external dcl 988 ref 800 bj_txte_util$rolled_back_mark 000060 constant entry external dcl 987 ref 758 bj_txte_util$simple_commit 000054 constant entry external dcl 985 ref 726 bj_txte_util$synchronize_txte_pste 000046 constant entry external dcl 982 ref 482 bj_uid 1 based bit(36) level 2 in structure "bj_ppte" dcl 2-39 in procedure "bjm_write$begin_mark" ref 526 bj_uid 1 based bit(36) level 2 in structure "bj_txte" dcl 3-28 in procedure "bjm_write$begin_mark" set ref 526* bjm_data_$bj_code 000072 external static fixed bin(35,0) dcl 1-19 set ref 427 449* bjm_data_$bj_default_error_label 000074 external static label variable dcl 1-21 ref 419 882 bjm_data_$bj_exit_err 000070 external static label variable dcl 1-17 set ref 419* 448* 882* bjm_data_$bj_operation 000066 external static char(32) unaligned dcl 1-15 set ref 422* 441 441* 881* bjm_data_$bj_ppt_ptr 000016 external static pointer dcl 940 ref 530 bjm_data_$bj_pst_ptr 000020 external static pointer dcl 941 ref 125 125 160 160 214 214 255 255 306 306 357 357 402 402 buff_len 000112 automatic fixed bin(17,0) dcl 926 set ref 339* 385* 787 789 791 831 833 835 buff_ptr 000110 automatic pointer dcl 925 set ref 338* 384* 789 833 byte_length 15 based fixed bin(24,0) array level 3 dcl 5-57 set ref 667* byte_offset 14 based fixed bin(24,0) array level 3 dcl 5-57 set ref 665* checkpoint_no 000103 automatic fixed bin(35,0) dcl 921 in procedure "bjm_write$begin_mark" set ref 291* checkpoint_no 7 based fixed bin(35,0) level 2 in structure "bj_rolled_back_rec" dcl 5-41 in procedure "bjm_write$begin_mark" set ref 748* ci_no 11 based fixed bin(35,0) level 2 in structure "bj_before_image" dcl 5-57 in procedure "bjm_write$begin_mark" set ref 659* ci_no 000106 automatic fixed bin(24,0) unsigned dcl 924 in procedure "bjm_write$begin_mark" set ref 196* 659 ci_parts based structure level 1 dcl 6-27 ci_parts_ptr 000154 automatic pointer initial dcl 6-35 set ref 197* 6-35* 589 590 660 664 665 666 672 cip_number_of_parts 000156 automatic fixed bin(17,0) initial dcl 6-36 set ref 6-36* cleanup 000134 stack reference condition dcl 1002 ref 115 154 208 249 300 351 396 cleanup_code 000100 automatic fixed bin(35,0) dcl 877 set ref 879* code 000116 automatic fixed bin(35,0) dcl 929 set ref 427* 430 464* 472* 487* 489* 497* 500* 501* 504* 505* commit_mark_delta_txn 000651 automatic fixed bin(17,0) dcl 696 set ref 709* 713* 725* curr_checkpoint_rec_id 13 based bit(36) level 3 dcl 3-28 set ref 747 current_operation 21 based char(4) level 3 dcl 3-28 set ref 482 538* 862* default_bj_before_image_space 000230 automatic char(1024) dcl 576 set ref 583 delta_txn 000133 automatic fixed bin(17,0) dcl 933 set ref 596* 598* 618* 633* dm_data_$bj_txt_ptr 000014 external static pointer dcl 939 ref 460 521 dm_data_$current_txn_id 000010 external static bit(36) dcl 937 ref 198 341 386 dm_data_$current_txn_index 000012 external static fixed bin(17,0) dcl 938 ref 199 342 387 dm_error_$bj_bad_tid 000026 external static fixed bin(35,0) dcl 944 ref 487 dm_error_$bj_bad_txt_version 000024 external static fixed bin(35,0) dcl 943 ref 464 dm_error_$bj_cant_abort 000032 external static fixed bin(35,0) dcl 946 ref 504 dm_error_$bj_cant_commit 000034 external static fixed bin(35,0) dcl 947 ref 500 dm_error_$bj_recursive_invoc 000030 external static fixed bin(35,0) dcl 945 ref 444 dm_error_$no_current_transaction 000022 external static fixed bin(35,0) dcl 942 ref 472 489 505 dm_system_data_$max_n_transactions 000076 external static fixed bin(17,0) dcl 4-10 ref 470 entry 40 based structure array level 2 dcl 3-20 set ref 478 522 entry_state 2 based structure level 2 dcl 3-28 first_bj_rec_id 14 based bit(36) level 3 dcl 3-28 set ref 169 264 315 fm_oid 10 based bit(36) level 2 in structure "bj_fm_handler_rec" dcl 5-69 in procedure "bjm_write$begin_mark" set ref 785* 829* fm_oid 000105 automatic bit(36) dcl 923 in procedure "bjm_write$begin_mark" set ref 195* 337* 383* 658 785 829 fm_oid 10 based bit(36) level 2 in structure "bj_before_image" dcl 5-57 in procedure "bjm_write$begin_mark" set ref 658* fm_postcommit_delta_n_txn 001310 automatic fixed bin(17,0) dcl 813 set ref 815* 817* 845* fm_rollback_delta_n_txn 001100 automatic fixed bin(17,0) dcl 769 set ref 771* 773* 799* fm_uid 7 based bit(36) level 2 in structure "bj_before_image" dcl 5-57 in procedure "bjm_write$begin_mark" set ref 657* fm_uid 7 based bit(36) level 2 in structure "bj_fm_handler_rec" dcl 5-69 in procedure "bjm_write$begin_mark" set ref 784* 828* fm_uid 000104 automatic bit(36) dcl 922 in procedure "bjm_write$begin_mark" set ref 194* 336* 382* 657 784 828 handler_buffer 001110 automatic char(512) dcl 811 in procedure "WRITE_FM_POSTCOMMIT_HANDLER" set ref 819 handler_buffer 000700 automatic char(512) dcl 767 in procedure "WRITE_FM_ROLLBACK_HANDLER" set ref 775 header based structure level 2 in structure "bj_rolled_back_rec" dcl 5-41 in procedure "bjm_write$begin_mark" header based structure level 2 in structure "bj_before_image" dcl 5-57 in procedure "bjm_write$begin_mark" header based structure level 2 in structure "bj_fm_handler_rec" dcl 5-69 in procedure "bjm_write$begin_mark" image based char level 2 dcl 5-57 set ref 672* image_len 13 based fixed bin(24,0) level 2 dcl 5-57 set ref 662* 668 670* 670 672 info_buffer based char unaligned dcl 812 in procedure "WRITE_FM_POSTCOMMIT_HANDLER" ref 833 info_buffer based char unaligned dcl 768 in procedure "WRITE_FM_ROLLBACK_HANDLER" ref 789 info_bytes 13 based char level 2 dcl 5-69 set ref 789* 833* info_len 12 based fixed bin(17,0) level 2 dcl 5-69 set ref 787* 789 831* 833 last_bj_rec_id 15 based bit(36) level 3 dcl 3-28 set ref 558 596 654 717 749 771 780 815 824 last_completed_operation 2 based char(4) level 3 dcl 3-28 set ref 172* 267* 497 501 541* 702 last_fm_postcommit_handler_rec_id 20 based bit(36) level 3 dcl 3-28 set ref 706 726 830 last_rolled_back_rec_id 10 based bit(36) level 2 dcl 5-41 set ref 749* length_in_bytes 3 based fixed bin(17,0) array level 3 dcl 6-27 ref 590 666 local_ptr 4 based pointer array level 3 dcl 6-27 ref 672 meters 46 based structure level 2 in structure "bj_pste" dcl 8-48 in procedure "bjm_write$begin_mark" meters 16 based structure level 2 in structure "bj_pst" dcl 7-18 in procedure "bjm_write$begin_mark" my_bj_aborted_record 000212 automatic structure level 1 dcl 551 set ref 553 560 566 566 my_bj_committed_record 000642 automatic structure level 1 dcl 695 set ref 700 719 725 725 my_bj_rolled_back_record 000660 automatic structure level 1 dcl 740 set ref 742 751 757 757 my_name 000117 automatic char(32) unaligned dcl 930 set ref 100* 149* 203* 244* 295* 346* 391* 441 497 501 n_bi_bytes_written 50 based fixed bin(71,0) level 3 dcl 8-48 set ref 642* 642 n_bi_written 46 based fixed bin(71,0) level 3 dcl 8-48 set ref 641* 641 n_bytes_written 17 based fixed bin(35,0) level 3 dcl 3-28 set ref 564 616 631 723 797 843 n_calls_abort 22 based fixed bin(71,0) level 3 dcl 7-18 set ref 160* 160 n_calls_before_image 20 based fixed bin(71,0) level 3 dcl 7-18 set ref 214* 214 n_calls_begin_txn 16 based fixed bin(71,0) level 3 dcl 7-18 set ref 125* 125 n_calls_commit 24 based fixed bin(71,0) level 3 dcl 7-18 set ref 255* 255 n_calls_fm_pc_mark 30 based fixed bin(71,0) level 3 dcl 7-18 set ref 402* 402 n_calls_fm_rbh 32 based fixed bin(71,0) level 3 dcl 7-18 set ref 357* 357 n_calls_rb_mark 26 based fixed bin(71,0) level 3 dcl 7-18 set ref 306* 306 n_ci_held 000113 automatic fixed bin(27,0) dcl 927 set ref 340* 799* n_parts 12 based fixed bin(17,0) level 2 dcl 5-57 set ref 584* 660* 672 n_rec_bytes 000132 automatic fixed bin(17,0) dcl 932 set ref 560* 564 566* 586* 590* 590 602 608 616 618* 631 633* 642 719* 723 725* 751* 755 757* 791* 797 799* 835* 843 845* n_rec_written 16 based fixed bin(35,0) level 3 dcl 3-28 set ref 559 563 615 630 655 718 722 782 796 826 842 n_txn_started 60 based fixed bin(71,0) level 3 dcl 8-48 set ref 127* 127 number_of_parts based fixed bin(17,0) level 2 dcl 6-27 ref 589 660 664 offset_in_bytes 2 based fixed bin(17,0) array level 3 dcl 6-27 ref 665 ok_to_write 3 based bit(1) level 3 dcl 3-28 set ref 171* 266* 495 528* 542* one_ci_part based char unaligned dcl 579 ref 672 operator_info 6 based structure level 2 dcl 3-28 owner_info 4 based structure level 2 dcl 3-28 p_abort_code parameter fixed bin(35,0) dcl 908 set ref 139 147* 150 p_before_image_code parameter fixed bin(35,0) dcl 909 set ref 189 201* 204 p_begin_code parameter fixed bin(35,0) dcl 910 set ref 90 98* 101 108* 109 p_bi_time_stamp parameter fixed bin(71,0) dcl 906 set ref 189 644* p_bj_oid parameter bit(36) dcl 897 ref 90 105 105 p_buff_len parameter fixed bin(17,0) dcl 904 ref 331 339 377 385 p_buff_ptr parameter pointer dcl 903 ref 331 338 377 384 p_checkpoint_no parameter fixed bin(35,0) dcl 898 ref 284 291 p_ci_no parameter fixed bin(24,0) unsigned dcl 901 ref 189 196 p_ci_parts_ptr parameter pointer dcl 902 ref 189 197 p_commit_code parameter fixed bin(35,0) dcl 911 set ref 234 242* 245 p_delta_image parameter fixed bin(27,0) dcl 858 set ref 852 866* p_delta_txn parameter fixed bin(17,0) dcl 857 set ref 852 866* p_fm_oid parameter bit(36) dcl 900 ref 189 195 331 337 377 383 p_fm_postcommit_code parameter fixed bin(35,0) dcl 914 set ref 377 389* 392 p_fm_rollback_code parameter fixed bin(35,0) dcl 913 set ref 331 344* 347 p_fm_uid parameter bit(36) dcl 899 ref 189 194 331 336 377 382 p_fr_time_stamp parameter fixed bin(71,0) dcl 907 set ref 331 802* p_n_bytes parameter fixed bin(17,0) dcl 856 set ref 852 866* p_n_ci_held parameter fixed bin(27,0) dcl 905 ref 331 340 p_rec_ptr parameter pointer dcl 855 set ref 852 862 866* p_rolled_back_code parameter fixed bin(35,0) dcl 912 set ref 284 293* 296 p_tid parameter bit(36) dcl 895 ref 90 95 139 144 234 239 284 289 p_tix parameter fixed bin(17,0) dcl 896 ref 90 96 139 145 234 240 284 290 part 2 based structure array level 2 in structure "ci_parts" dcl 6-27 in procedure "bjm_write$begin_mark" part 14 based structure array level 2 in structure "bj_before_image" dcl 5-57 in procedure "bjm_write$begin_mark" set ref 586 part_len 000631 automatic fixed bin(17,0) dcl 578 set ref 666* 667 670 672 672 part_no 000630 automatic fixed bin(17,0) dcl 577 set ref 589* 590* 664* 665 665 666 667 672* pending_bj_rec_id 22 based bit(36) level 3 dcl 3-28 set ref 562* 614* 629* 721* 753* 795* 841* 866* pending_n_bytes_written 24 based fixed bin(35,0) level 3 dcl 3-28 set ref 564* 616* 631* 723* 755* 797* 843* pending_n_rec_written 23 based fixed bin(35,0) level 3 dcl 3-28 set ref 563* 615* 630* 722* 754* 796* 842* ppte_ptr 10 based pointer level 3 dcl 3-28 set ref 512 533* prev_fm_handler_rec_id 11 based bit(36) level 2 dcl 5-69 set ref 786* 830* prev_rec_byte_size 4 based fixed bin(24,0) level 3 dcl 5-69 set ref 781* 825* prev_rec_id 3 based bit(36) level 3 in structure "bj_fm_handler_rec" dcl 5-69 in procedure "bjm_write$begin_mark" set ref 780* 824* prev_rec_id 3 based bit(36) level 2 in structure "bj_aborted_rec" dcl 5-39 in procedure "bjm_write$begin_mark" set ref 558* prev_rec_id 3 based bit(36) level 3 in structure "bj_rolled_back_rec" dcl 5-41 in procedure "bjm_write$begin_mark" set ref 747* prev_rec_id 3 based bit(36) level 3 in structure "bj_before_image" dcl 5-57 in procedure "bjm_write$begin_mark" set ref 654* prev_rec_id 3 based bit(36) level 2 in structure "bj_committed_rec" dcl 5-35 in procedure "bjm_write$begin_mark" set ref 717* process_id 4 based bit(36) level 3 in structure "bj_txte" dcl 3-28 in procedure "bjm_write$begin_mark" set ref 530* 532 557 653 716 746 779 823 process_id 2 based bit(36) level 3 in structure "bj_fm_handler_rec" dcl 5-69 in procedure "bjm_write$begin_mark" set ref 779* 823* process_id 2 based bit(36) level 3 in structure "bj_before_image" dcl 5-57 in procedure "bjm_write$begin_mark" set ref 653* process_id 6 based bit(36) level 2 in structure "bj_ppt" dcl 2-18 in procedure "bjm_write$begin_mark" ref 530 process_id 2 based bit(36) level 2 in structure "bj_aborted_rec" dcl 5-39 in procedure "bjm_write$begin_mark" set ref 557* process_id 2 based bit(36) level 3 in structure "bj_rolled_back_rec" dcl 5-41 in procedure "bjm_write$begin_mark" set ref 746* process_id 6 based bit(36) level 3 in structure "bj_txte" dcl 3-28 in procedure "bjm_write$begin_mark" set ref 532* process_id 2 based bit(36) level 2 in structure "bj_committed_rec" dcl 5-35 in procedure "bjm_write$begin_mark" set ref 716* records_info 13 based structure level 2 dcl 3-28 set ref 536* rel builtin function dcl 995 ref 586 586 return_code based fixed bin(35,0) dcl 951 set ref 430* 444* return_code_ptr 000130 automatic pointer dcl 931 set ref 101* 150* 204* 245* 296* 347* 392* 430 444 size builtin function dcl 996 ref 560 719 751 791 835 substr builtin function dcl 997 set ref 672* tid 1 based bit(36) level 3 in structure "bj_before_image" dcl 5-57 in procedure "bjm_write$begin_mark" set ref 652* tid based bit(36) level 2 in structure "bj_txte" dcl 3-28 in procedure "bjm_write$begin_mark" set ref 485 487 525* 540* tid 1 based bit(36) level 3 in structure "bj_rolled_back_rec" dcl 5-41 in procedure "bjm_write$begin_mark" set ref 745* tid 1 based bit(36) level 3 in structure "bj_fm_handler_rec" dcl 5-69 in procedure "bjm_write$begin_mark" set ref 778* 822* tid 1 based bit(36) level 2 in structure "bj_aborted_rec" dcl 5-39 in procedure "bjm_write$begin_mark" set ref 556* tid 1 based bit(36) level 2 in structure "bj_committed_rec" dcl 5-35 in procedure "bjm_write$begin_mark" set ref 715* time_stamp 000114 automatic fixed bin(71,0) dcl 928 set ref 644 802 866* tx_rec_no 5 based fixed bin(35,0) level 2 in structure "bj_committed_rec" dcl 5-35 in procedure "bjm_write$begin_mark" set ref 718* tx_rec_no 5 based fixed bin(35,0) level 3 in structure "bj_fm_handler_rec" dcl 5-69 in procedure "bjm_write$begin_mark" set ref 782* 826* tx_rec_no 5 based fixed bin(35,0) level 2 in structure "bj_aborted_rec" dcl 5-39 in procedure "bjm_write$begin_mark" set ref 559* tx_rec_no 5 based fixed bin(35,0) level 3 in structure "bj_before_image" dcl 5-57 in procedure "bjm_write$begin_mark" set ref 655* tx_rec_no 5 based fixed bin(35,0) level 3 in structure "bj_rolled_back_rec" dcl 5-41 in procedure "bjm_write$begin_mark" set ref 750* txn_id 000100 automatic bit(36) dcl 918 set ref 95* 144* 198* 239* 289* 341* 386* 470 485 540 556 652 715 745 778 822 txn_index 000101 automatic fixed bin(17,0) dcl 919 set ref 96* 145* 199* 240* 290* 342* 387* 470 470 478 522 type based char(4) level 3 in structure "bj_fm_handler_rec" dcl 5-69 in procedure "bjm_write$begin_mark" set ref 777* 821* type based char(4) level 2 in structure "bj_rec_hdr" dcl 5-21 in procedure "bjm_write$begin_mark" ref 862 type based char(4) level 3 in structure "bj_before_image" dcl 5-57 in procedure "bjm_write$begin_mark" set ref 651* type based char(4) level 3 in structure "bj_rolled_back_rec" dcl 5-41 in procedure "bjm_write$begin_mark" set ref 744* type based char(4) level 2 in structure "bj_committed_rec" dcl 5-35 in procedure "bjm_write$begin_mark" set ref 708* 712* type based char(4) level 2 in structure "bj_aborted_rec" dcl 5-39 in procedure "bjm_write$begin_mark" set ref 555* unspec builtin function dcl 998 set ref 536* version based fixed bin(17,0) level 2 dcl 3-20 ref 462 NAMES DECLARED BY DECLARE STATEMENT AND NEVER REFERENCED. BJ_PPTE_VERSION_1 internal static fixed bin(17,0) initial dcl 2-14 BJ_PPT_VERSION_1 internal static fixed bin(17,0) initial dcl 2-13 BJ_PSTE_VERSION_2 internal static fixed bin(17,0) initial dcl 8-42 BJ_PST_VERSION_1 internal static fixed bin(17,0) initial dcl 7-14 bj_before_image_n_parts automatic fixed bin(17,0) dcl 5-81 bj_begin_commit_rec based structure level 1 dcl 5-37 bj_fm_handler_info_len automatic fixed bin(24,0) dcl 5-83 bj_ppt_ptr automatic pointer dcl 2-16 bj_pst_ptr automatic pointer dcl 7-16 bj_rollback_handler_rec based structure level 1 dcl 5-46 bj_rollback_info_len automatic fixed bin(24,0) dcl 5-80 bj_rollback_name_len automatic fixed bin(24,0) dcl 5-79 dm_system_data_$bj_max_n_journals external static fixed bin(17,0) dcl 4-8 dm_system_data_$bj_max_n_processes external static fixed bin(17,0) dcl 4-9 NAMES DECLARED BY EXPLICIT CONTEXT. APPEND 002275 constant entry internal dcl 852 ref 566 618 633 725 757 799 845 DO_COMPLETE_COMMIT_MARK_OPERATION 001700 constant label dcl 704 EMERGENCY_CLEANUP 002334 constant entry internal dcl 874 ref 115 154 208 249 300 351 396 432 ENTER_BJM 001015 constant entry internal dcl 438 ref 117 156 210 251 302 353 398 FILL_BEFORE_IMAGE 001554 constant entry internal dcl 648 ref 612 627 INITIALIZE_TRANSACTION 001166 constant entry internal dcl 518 ref 121 MAKE_LARGE_BEFORE_IMAGE 001405 constant label dcl 605 VALIDATE_TRANSACTION 001041 constant entry internal dcl 455 ref 165 219 260 311 362 407 WRITE_ABORTED_MARK 001244 constant entry internal dcl 548 ref 178 WRITE_BEFORE_IMAGE 001330 constant entry internal dcl 573 ref 223 WRITE_COMMITTED_MARK 001661 constant entry internal dcl 685 ref 273 WRITE_FM_POSTCOMMIT_HANDLER 002167 constant entry internal dcl 808 ref 411 WRITE_FM_ROLLBACK_HANDLER 002061 constant entry internal dcl 764 ref 366 WRITE_ROLLED_BACK_MARK 002001 constant entry internal dcl 737 ref 320 bjm_local_error_exit 001006 constant label dcl 430 ref 465 473 490 507 bjm_nonlocal_error_exit 001003 constant label dcl 427 ref 448 bjm_return 001002 constant label dcl 424 ref 109 433 445 bjm_wrap_up 000767 constant label dcl 419 ref 132 173 182 227 268 277 315 324 370 415 bjm_write$aborted_mark 000236 constant entry external dcl 139 bjm_write$before_image 000330 constant entry external dcl 189 bjm_write$begin_mark 000131 constant entry external dcl 90 bjm_write$committed_mark 000421 constant entry external dcl 234 bjm_write$fm_postcommit_handler 000700 constant entry external dcl 377 bjm_write$fm_rollback_handler 000602 constant entry external dcl 331 bjm_write$rolled_back_mark 000512 constant entry external dcl 284 NAME DECLARED BY CONTEXT OR IMPLICATION. null builtin function ref 6-35 STORAGE REQUIREMENTS FOR THIS PROGRAM. Object Text Link Symbol Defs Static Start 0 0 3214 3314 2364 3224 Length 3760 2364 100 427 630 0 BLOCK NAME STACK SIZE TYPE WHY NONQUICK/WHO SHARES STACK FRAME bjm_write$begin_mark 824 external procedure is an external procedure. on unit on line 115 64 on unit on unit on line 154 64 on unit on unit on line 208 64 on unit on unit on line 249 64 on unit on unit on line 300 64 on unit on unit on line 351 64 on unit on unit on line 396 64 on unit ENTER_BJM internal procedure shares stack frame of external procedure bjm_write$begin_mark. VALIDATE_TRANSACTION internal procedure shares stack frame of external procedure bjm_write$begin_mark. INITIALIZE_TRANSACTION internal procedure shares stack frame of external procedure bjm_write$begin_mark. WRITE_ABORTED_MARK internal procedure shares stack frame of external procedure bjm_write$begin_mark. WRITE_BEFORE_IMAGE internal procedure shares stack frame of external procedure bjm_write$begin_mark. begin block on line 605 82 begin block uses auto adjustable storage. FILL_BEFORE_IMAGE 67 internal procedure is called by several nonquick procedures. WRITE_COMMITTED_MARK internal procedure shares stack frame of external procedure bjm_write$begin_mark. WRITE_ROLLED_BACK_MARK internal procedure shares stack frame of external procedure bjm_write$begin_mark. WRITE_FM_ROLLBACK_HANDLER internal procedure shares stack frame of external procedure bjm_write$begin_mark. WRITE_FM_POSTCOMMIT_HANDLER internal procedure shares stack frame of external procedure bjm_write$begin_mark. APPEND 80 internal procedure is called by several nonquick procedures. EMERGENCY_CLEANUP 70 internal procedure is called by several nonquick procedures. STORAGE FOR AUTOMATIC VARIABLES. STACK FRAME LOC IDENTIFIER BLOCK NAME EMERGENCY_CLEANUP 000100 cleanup_code EMERGENCY_CLEANUP begin block on line 605 000100 bj_before_image_space begin block on line 605 bjm_write$begin_mark 000100 txn_id bjm_write$begin_mark 000101 txn_index bjm_write$begin_mark 000102 bj_oid bjm_write$begin_mark 000103 checkpoint_no bjm_write$begin_mark 000104 fm_uid bjm_write$begin_mark 000105 fm_oid bjm_write$begin_mark 000106 ci_no bjm_write$begin_mark 000110 buff_ptr bjm_write$begin_mark 000112 buff_len bjm_write$begin_mark 000113 n_ci_held bjm_write$begin_mark 000114 time_stamp bjm_write$begin_mark 000116 code bjm_write$begin_mark 000117 my_name bjm_write$begin_mark 000130 return_code_ptr bjm_write$begin_mark 000132 n_rec_bytes bjm_write$begin_mark 000133 delta_txn bjm_write$begin_mark 000142 bj_ppte_ptr bjm_write$begin_mark 000144 bj_txt_ptr bjm_write$begin_mark 000146 bj_txte_ptr bjm_write$begin_mark 000150 bj_rec_hdr_ptr bjm_write$begin_mark 000152 bj_before_image_len bjm_write$begin_mark 000154 ci_parts_ptr bjm_write$begin_mark 000156 cip_number_of_parts bjm_write$begin_mark 000160 bj_pste_ptr bjm_write$begin_mark 000212 my_bj_aborted_record WRITE_ABORTED_MARK 000230 default_bj_before_image_space WRITE_BEFORE_IMAGE 000630 part_no WRITE_BEFORE_IMAGE 000631 part_len WRITE_BEFORE_IMAGE 000642 my_bj_committed_record WRITE_COMMITTED_MARK 000651 commit_mark_delta_txn WRITE_COMMITTED_MARK 000660 my_bj_rolled_back_record WRITE_ROLLED_BACK_MARK 000700 handler_buffer WRITE_FM_ROLLBACK_HANDLER 001100 fm_rollback_delta_n_txn WRITE_FM_ROLLBACK_HANDLER 001110 handler_buffer WRITE_FM_POSTCOMMIT_HANDLER 001310 fm_postcommit_delta_n_txn WRITE_FM_POSTCOMMIT_HANDLER THE FOLLOWING EXTERNAL OPERATORS ARE USED BY THIS PROGRAM. enter_begin leave_begin call_ext_out call_int_this call_int_other return alloc_auto_adj mpfx2 enable ext_entry int_entry THE FOLLOWING EXTERNAL ENTRIES ARE CALLED BY THIS PROGRAM. before_journal_manager_$get_default_bj bj_cleanup_tables$handler bj_oid_util$get_ptr bj_storage_append bj_txte_util$aborted_mark bj_txte_util$before_image bj_txte_util$complex_commit bj_txte_util$fm_postcommit_handler bj_txte_util$fm_rollback_handler bj_txte_util$rolled_back_mark bj_txte_util$simple_commit bj_txte_util$synchronize_txte_pste THE FOLLOWING EXTERNAL VARIABLES ARE USED BY THIS PROGRAM. bjm_data_$bj_code bjm_data_$bj_default_error_label bjm_data_$bj_exit_err bjm_data_$bj_operation bjm_data_$bj_ppt_ptr bjm_data_$bj_pst_ptr dm_data_$bj_txt_ptr dm_data_$current_txn_id dm_data_$current_txn_index dm_error_$bj_bad_tid dm_error_$bj_bad_txt_version dm_error_$bj_cant_abort dm_error_$bj_cant_commit dm_error_$bj_recursive_invoc dm_error_$no_current_transaction dm_system_data_$max_n_transactions LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC 6 35 000117 6 36 000121 90 000124 95 000137 96 000142 98 000144 100 000145 101 000150 105 000152 108 000156 109 000167 115 000172 117 000214 121 000215 125 000216 127 000224 132 000231 139 000232 144 000244 145 000247 147 000251 149 000252 150 000255 154 000257 156 000301 160 000302 165 000310 169 000311 171 000314 172 000315 173 000317 178 000320 182 000321 189 000322 194 000336 195 000341 196 000343 197 000345 198 000350 199 000353 201 000355 203 000356 204 000361 208 000363 210 000405 214 000406 219 000414 223 000415 227 000416 234 000417 239 000427 240 000432 242 000434 244 000435 245 000440 249 000442 251 000464 255 000465 260 000473 264 000474 266 000477 267 000500 268 000502 273 000503 277 000504 284 000505 289 000520 290 000523 291 000525 293 000527 295 000530 296 000533 300 000535 302 000557 306 000560 311 000566 315 000567 320 000572 324 000573 331 000574 336 000610 337 000613 338 000615 339 000620 340 000622 341 000624 342 000627 344 000631 346 000632 347 000635 351 000637 353 000661 357 000662 362 000670 366 000671 370 000672 377 000673 382 000706 383 000711 384 000713 385 000716 386 000720 387 000723 389 000725 391 000726 392 000731 396 000733 398 000755 402 000756 407 000764 411 000765 415 000766 419 000767 422 000776 424 001002 427 001003 430 001006 432 001010 433 001014 438 001015 441 001016 444 001030 445 001032 448 001033 449 001037 451 001040 455 001041 460 001042 462 001046 464 001051 465 001053 470 001054 472 001063 473 001065 478 001066 482 001072 485 001105 487 001110 489 001116 490 001121 495 001122 497 001125 500 001136 501 001142 504 001153 505 001157 507 001162 512 001163 514 001165 518 001166 521 001167 522 001173 523 001200 525 001210 526 001211 528 001215 530 001216 532 001223 533 001224 534 001225 536 001230 538 001233 540 001235 541 001237 542 001241 544 001243 548 001244 553 001245 555 001247 556 001251 557 001253 558 001256 559 001260 560 001264 562 001266 563 001267 564 001273 566 001277 567 001320 569 001327 573 001330 583 001331 584 001333 586 001335 589 001351 590 001362 592 001371 596 001373 598 001401 602 001402 605 001405 608 001410 610 001420 612 001422 614 001427 615 001432 616 001436 618 001442 619 001461 621 001471 623 001472 627 001473 629 001477 630 001501 631 001505 633 001511 634 001527 640 001536 641 001541 642 001544 644 001547 646 001552 648 001553 651 001561 652 001564 653 001567 654 001572 655 001574 657 001600 658 001602 659 001604 660 001606 662 001610 664 001611 665 001622 666 001633 667 001635 668 001636 670 001641 672 001643 677 001656 679 001660 685 001661 700 001662 702 001664 706 001700 708 001702 709 001704 710 001706 712 001707 713 001711 715 001712 716 001714 717 001716 718 001720 719 001724 721 001726 722 001727 723 001733 725 001737 726 001756 728 001771 733 002000 737 002001 742 002002 744 002004 745 002006 746 002010 747 002013 748 002015 749 002016 750 002020 751 002022 753 002024 754 002025 755 002027 757 002031 758 002051 760 002060 764 002061 771 002062 773 002070 775 002071 777 002073 778 002075 779 002077 780 002102 781 002104 782 002105 784 002111 785 002113 786 002115 787 002116 789 002120 791 002124 795 002127 796 002130 797 002134 799 002140 800 002154 802 002163 804 002166 808 002167 815 002170 817 002176 819 002177 821 002201 822 002203 823 002205 824 002210 825 002212 826 002213 828 002217 829 002221 830 002223 831 002225 833 002227 835 002233 841 002236 842 002237 843 002243 845 002247 846 002264 848 002273 852 002274 862 002302 866 002310 870 002332 874 002333 879 002341 881 002347 882 002354 885 002362 ----------------------------------------------------------- Historical Background This edition of the Multics software materials and documentation is provided and donated to Massachusetts Institute of Technology by Group BULL including BULL HN Information Systems Inc. as a contribution to computer science knowledge. This donation is made also to give evidence of the common contributions of Massachusetts Institute of Technology, Bell Laboratories, General Electric, Honeywell Information Systems Inc., Honeywell BULL Inc., Groupe BULL and BULL HN Information Systems Inc. to the development of this operating system. Multics development was initiated by Massachusetts Institute of Technology Project MAC (1963-1970), renamed the MIT Laboratory for Computer Science and Artificial Intelligence in the mid 1970s, under the leadership of Professor Fernando Jose Corbato. Users consider that Multics provided the best software architecture for managing computer hardware properly and for executing programs. Many subsequent operating systems incorporated Multics principles. Multics was distributed in 1975 to 2000 by Group Bull in Europe , and in the U.S. by Bull HN Information Systems Inc., as successor in interest by change in name only to Honeywell Bull Inc. and Honeywell Information Systems Inc. . ----------------------------------------------------------- Permission to use, copy, modify, and distribute these programs and their documentation for any purpose and without fee is hereby granted,provided that the below copyright notice and historical background appear in all copies and that both the copyright notice and historical background and this permission notice appear in supporting documentation, and that the names of MIT, HIS, BULL or BULL HN not be used in advertising or publicity pertaining to distribution of the programs without specific prior written permission. Copyright 1972 by Massachusetts Institute of Technology and Honeywell Information Systems Inc. Copyright 2006 by BULL HN Information Systems Inc. Copyright 2006 by Bull SAS All Rights Reserved