The trial of two men charged with killing a young mother in 2010 was abruptly postponed Thursday after Suffolk Superior Court Judge Linda Giles learned that two potential witnesses were among four men stabbed in downtown Boston Wednesday afternoon.

Giles said from the bench that she was concerned that the wounds suffered by the two men on the witness list were too severe to allow court appearances any time soon. But having to delay the trial, she said, disturbed her.

“I am outraged that this could set a precedent that all you have to do to derail a first-degree murder trial in Suffolk Superior Court is to attack some of the participants who are supporters for either side,’’ Giles said. “That sets a terrible precedent, and I am extremely reluctant to [postpone] this trial, but I am basing it on two potential defense witnesses, particularly, who are in the hospital.’’

Jury selection had begun Wednesday, and opening statements were expected Thursday. Instead, the trial was rescheduled for Sept. 12. Giles dismissed the nine jurors who had been chosen.

Giles is presiding in the first-degree murder trial of Kadeem Foreman and Terrell Rainey, two Dorchester men accused of shooting Toneika Jones to death inside the foyer of a building at 183 Harvard St. in Dorchester on May 22, 2010. Jones, the mother of four young children, was caught in gunfire as she arrived with friends for a party.

The two stabbing victims were on the prosecution’s witness list and on the witness list filed on behalf of Foreman, which means they could have been called by the prosecution, the defense, or not at all during the trial, said Jake Wark, spokesman for Suffolk District Attorney Daniel F. Conley.

Wark, however, suggested the stabbings may be connected to old clashes, rather than the trial that was about to begin.

Investigators have found “no evidence at this point that the attacks were a calculated attempt to derail the trial,’’ he said, and the two groups in the incident had had conflicts in the past.

“The preliminary investigation suggests that a long-term animus exists predating the murder and the trial amongst the parties believed to be involved,’’ he said.

It was not clear whether the two groups involved in the stabbing had encountered each other at the courthouse, perhaps as part of the trial proceedings, or had simply met by chance near Tremont and Beacon streets, where the attack occurred.

In court, Assistant Suffolk District Attorney Mark Zanini said one of those potential witnesses was stabbed in the back and the second was stabbed in the colon. He said during the rescheduling hearing that the abdomen of one of the witnesses had been “sliced open.’’

Zanini told the judge earlier that he was concerned not only about whether the physical condition of the witnesses would prohibit them from testifying soon, but also about whether they would participate in the trial after the violence.

Foreman and Rainey have pleaded not guilty to all charges.

“Both of our clients have made it clear from the start that they are not guilty of these charges that have been lodged against them,’’ said Foreman’s attorney, Michael Doolin. “We’re disappointed in what happened [Wednesday]. From our perspective, I think it’s a necessity that this case get postponed due to circumstances that were outlined in court.’’

Rainey’s attorney, Stephen J. Weymouth, said in court and to reporters afterward that he wanted a brief wait with the hope that the stabbing victims would be sufficiently recovered to take the stand by next week.

“I think it was a little premature’’ for Giles to delay the trial, he said. “I understand the stab wounds are serious . . . but it may be that we find out they will be available by next week. . . . I would have liked a little more investigation.’’

Weymouth said that Rainey has been waiting to go on trial for 25 months and that any further delay is a burden to him.

David Yannetti, a Boston-based criminal defense attorney and a former assistant district attorney in the Middlesex district attorney’s office, called Giles’s concerns legitimate. Yannetti is not connected with the trial or the defendants.

“If what happened, if that incident is connected to the trial, that would be a frightening thought,’’ Yannetti said in a phone interview. “It could cause a precedent that would have a negative effect.

“Many people subpoenaed to be a witness in a murder trial often concoct scenarios where they’d be in danger, and most times it’s not true. But this is troubling.’’

Wednesday’s stabbings occurred about 1:45 p.m. across from the Omni Parker House hotel.

Boston police said that no arrests have been made and that all four stabbing victims, described by police as men in their early 20s, are expected to survive.

On Wednesday after the stabbings, blood spattered the sidewalk across from historic King’s Chapel, drawing onlookers with cameras, lawmakers from the State House, and downtown lawyers to the area, which was cordoned off with yellow police tape.

Legal proceedings against Foreman and Rainey have been turbulent from the start. Two years ago, on the day the two trial defendants were scheduled to be arraigned in Dorchester District Court, the courthouse was evacuated after a woman inside the building told a member of the Boston Police Youth Violence Strike Force that she might have seen a firearm.

After a security sweep of the building, no weapon was found, and the crowd of about 400 was allowed back into the courthouse. Foreman and Rainey’s family members had arrived for the arraignment May 24, 2010, but were instructed by the attorneys to leave because of tensions in the courthouse.

John R. Ellement and Maria Cramer of the Globe staff contributed to this report. Brian R. Ballou can be reached at bballou@globe.com. Follow him on Twitter at @globeballou.

BostonGlobe.com complimentary digital access has been provided to you, without a subscription, for free starting today and ending in 14 days. After the free trial period, your free BostonGlobe.com digital access will stop immediately unless you sign up for BostonGlobe.com digital subscription. Current print and digital subscribers are not eligible for the free trial.

Thanks & Welcome to Globe.com

You now have unlimited access for the next two weeks.

BostonGlobe.com complimentary digital access has been provided to you, without a subscription, for free starting today and ending in 14 days. After the free trial period, your free BostonGlobe.com digital access will stop immediately unless you sign up for BostonGlobe.com digital subscription. Current print and digital subscribers are not eligible for the free trial.